Why do planets change their speeds when orbiting around the Sun ?
According to Kepler's second law which states that the areal velocity of a planet is constant.
And also the first law of Kepler gives us an idea that the orbit is not circular and is an ellipse, so the velocity of a planet has to change accordingly to maintain the constant areal velocity.
The ellipse has two foci and the sun is placed at one of the foci. For the planet to orbit same amount of area in the given interval of time, it has to move faster when it is closer to the sun (perihelion) and when it farther away (aphelion) from the sun it has to move slower.