What is the use of the fourth leg, the one with igbt in series with the diode, in the infineon power module?
By applying a DC shunt to the battery, the motor instead of free wheeling can regenerate and brake the motor. using the back EMF of the motor/generator.

There are different implementations including Battery Regen and single phase Remanence braking.

This is why there is a single B phase brake on a 3 phase UVW phase rectifier or bridge driver.