Is instantaneous speed always equal to the magnitude of instantaneous velocity? What about the infinitesimal time duration when the direction changes? How can it ALWAYS be equal?
This is due to the fact that for a small interval of time the distance is approximately the same as displacement. Just like in a curve, when we zoom into it small change in position is actually the distance covered. When divided by the same time change "$dt$" the magnitudes of the rates of change of displacement and distance which are velocity and speed respectively are equal.
Hope that helps!