"The oil cooler is in front of the water pump with coolant drawn through the heat exchanger."

Which one is modified by "with coolant drawn through the heat exchanger" in this context? The oil cooler or the water pump?

And also, when "with...” is used in a sentence, does it always modify the word or phrase right in front ot it? Or maybe it depends?

Help is very much appreciated.

Cheers
The sentence describes a system. Each statement modifies the system. "With" doesn't necessarily direct the modifiers here.

The chocolate layer is above the vanilla layer with candles on top. These three things all describe a birthday cake.
ResplendaThe oil cooler is in front of the water pump with coolant drawn through the heat exchanger.
If you said, "The oil cooler is in front of the water pump, and coolant is drawn through the heat exchanger," the meaning would be exactly the same.

We really need more information.

Most likely, the system has this provision for cooling hot oil. My guess is that the heat exchanger is the essential component of the oil cooler. Both fluids must flow through the heat exchanger, the hot oil and the coolant. Since we're using a water pump, the "coolant" must be water. So what pumps the oil?

If the coolant is "drawn through" the heat exchanger, that means the pump is sucking the water rather than pushing it.

So "in front of" cannot mean with respect to flow. It probably means that as you look at the unit, the pump sits behind the exchanger.

Describing a train:

The dining car is in front of the sleeping car, with the engine pulling the dining car.

OR , and the engine is pulling the dining car.

The "with" is just an optional way of connecting the additional information.
Thank you!