This is only for comfort. The part where you hold the trombone is not very ergonomical so we search for as comfortable position as possible, with control of the instrument. Try various hand positions yourself to see which works best for you. Ideally you should not lift you left shoulder at all (do check in a mirror, lifting left shoulder will with time lead to a lot of pain), the full weight and control should be in your left hand and the slide should not support the trombone weight and it should slide totally freely. (Ideals are one thing, reality a different). Whatever works for you.
I used to play the bass trombone and had a 2+2 hand positioning: 2 fingers in front of the bar and two behind. Index finger on the mouthpiece. This made the movement of the two valves controlled by left hand more free as well as getting a better balance.
There are varius devices available that improve the ergonomics. Some are extra support bars mounted on the instrument.