Which phenomenon is responsible for early sunrise and late sunset?
Refraction of light
The light initial journey is through the vacuum and then through the atmosphere of the earth and then it is finally seen by us. In this case, the vacuum will be a rarer medium and the earth's atmosphere with all its temperature changes, winds, different gases, will be a denser medium in comparison.
During sunrise, when the sun is just below the horizon, our atmosphere causes the light rays to bend and we see the sun early. Similarly, at sunset, the apparent position of the sun is visible to us and not the actual position but apparent position due to the same bending of light rays.