This new country needed a flag to represent its ideals and heritage. Much like the French tricolour, the colours were symbolic of what the people stood for.
Green, white and red were the colours used by insurgents under Miguel Hidalgo during the war of independence. While these unique colours made up the flag during this stage of history, they are not the true unofficial symbolism of these colours as used in flags.

Related: Red Gradients