Nothing special actually happens to the stellar objects themselves.
THE LIGHT FROM stellar objects that are moving away from Earth
appears to shift toward longer wavelengths (the red end of the spectrum),
compared with the wavelength it actually has when it leaves the stellar object.