The human eye is very complicated, and how it works still isn't totally understood. However, much research has been done into visual perception in an effort to understand how the human eye sees images and colour. Rods are sensitive to light intensity, but not frequency. They're used in low light conditions and don't see colour.
Cones are sensitive to different frequencies of light.
The frequencies correspond roughly to red, green and blue. Light passes through nerves and blood vessels and the ganglion cells before hitting the rods and cones. This sends electrical signals to the brain. The retina produces a chemical called rhodopsin, also known as visual purple, due to its colour in large quantities. When light strikes a receptor, the molecular structure of the rhodopsin changes and an electrical charge is released.