The different lengths of the fingers do not present a challenge for the pianist.
In addition to rotation there are other movements to use with rotation and the in-and-out movement is one of these movements.
It is unnatural for all the fingers to play in a straight line on the keyboard, therefore at no time should the fingers ever play in a straight line when played consecutively. This means if one is playing a passage
Variation in the Depth Dimension
The variation in the depth dimension may be as small as 1/8 of an inch but this "variation in the depth dimension" must be present when passages are played at the keyboard.
This also applies to a repeated note when played by the same finger.
When playing a repeated note using the same finger,
there is always a tiny in or out movement to bring the weight of the arm over each finger.
This movement involves the whole arm from the shoulder to the fingertip and this movement is not visible during performance.
Every finger is in an "in-and-out relationship" to the preceding and succeeding finger. If a finger is in the correct location, the arm must move in, in order to be over that finger. Because the finger, hand, forearm and upperarm are connected components, their motion must coordinated and unified when moving in-and-out in the depth dimension.
Likewise, the arm may move out to be positioned over that finger.
Moving in toward the backboard of the piano is the "in" movement, and
moving toward the keyboard player is the "out" movement.
The movement may be but a small distance, but it must be there and without this movement the passage will not feel coordinated.
By all means avoid big, unwieldy movements which would involve too much upperarm and bring on shoulder and neck pain.
Never move a limb to an extreme position.
Example: Playing a C Major scale
To play a C Major scale, follow the instructions given below.
Finger1: Play on key, the thumb always plays in.
Finger2: Play out, Balance hand over it.
Finger3: Moves out a little more, balance hand over it.
Finger1: Move in to play on key, balance.
Finger2: Moves out, balance over it.
Finger3: Moves out a little, balance.
Finger4: Moves out a little, balance.
Finger1: Move in toward keyboard as before.
The common misperception is that the C major scale is the easiest to play.
On the other hand, the B major scale uses long fingers which naturally fall on the black keys,
and the shaping employed during the passage brings the fingers to the correct place to set the keys in motion.