I think the terms are being used incorrectly here
Leaning means reducing the fuel:air mixture ratio
When in the climb, engines, even old ones with an altitude capsule, will reduce the weight of fuel going to the engine so as to attempt to maintain the the same fuel:air mixture.
At cruise power when you are safely away from the detonation boundry then the fuel:air mixture can be reduced[Leaned] so as to reduce fuel flow and increase range.
Now my experience is on old engines so modern electronic controls might make this wrong