This might be better answered by someone in the gene zone, but I will have a try. People with red hair have a recessive gene that is responsible for red hair (the melanocortin-1 receptor, or MC1R), which is found on chromosome 16.
This recessive gene is (I think) also responsible for people having lower levels of one of the types of skin pigments (melanin) There are two types of melanin that give hair and skin its colour: pheomelanin, the pigment that produces red and yellowish tones, and eumelanin, which gives skin and hair black and brown colouring. Red haired people have low levels of eumelanin, so they have paler skin too.
This can be good as they are able to absorb more vitamin D from the sun even when there is very little sunlight, but also bad as they are more at risk from skin cancers.