Dear Student,
This is because during sunrise and sunset the sun is near horizon and hence light has to cover maximum distance to reach our eyes due to which all the other colours except red light gets scattered in atmosphere and hence only red light reaches our eyes and gives us the sensation that sun is red.
Regards