Tiny molecules in our atmosphere cause light to scatter. That's why our sky looks blue: it's because the atmosphere scatters the bluish component of white sunlight. And it's why the sun looks reddish when it's near the horizon. Sunlight encounters more air molecules when the sun is low in the sky than when the sun is overhead. Even more blue light is scattered away, leaving mostly the reddish scattering∝
1
λ4
of white sunlight to travel the straighter path to your eyes. So the setting and rising sun looks red.