Copter: EKF3 Altitude source drift will RNGFND compensate drift?

Hello, I have a question related to Rangfinder.
As I understand in surface tracking, Rangfinder is used to compensate for terrain. if our source of altitude drift will those compensate drift? to my observation, it is. I might be wrong or not fully understand per document state.

Is it the same in Auto mode terrain following using a rangefinder?

Really appreciate with clarification, Thanks.