This I believe is a very interesting question with a very disappointing answer. It makes you say to yourself "Is that it?".
Similarly with flame tests in Chemistry, if you burned calcium with a strong flame, you will see the colour orange, with Lithium you see red and so on. Different atoms have different chemical properties and when these atoms bond to different atoms forming molecules in for example a lemon, the chemical properties of the surface of a lemon allow for the reflection of the wavelength of light that corresponds to yellow and absorbs all other wavelengths hence why lemons are yellow. This video explains the answer in more depth but nevertheless is still interesting.