Does the pump of a water tank have to be next to the water tank or can it be further down the line?
Assuming we're talking about a well here.
In a well system you need a pump to get the water out of the well and an accumulator tank to store it so the pump can fill the tank against some sort of air space for pressurized storage so the pump doesn't run all the time.
Submersibles may be in a 400ft well, or in a shallower well with either submersible or jet pump, but across the lot. What matters is that the pressure tank is in an enclosure to protect it from freezing and that the pressure switch be in the pump-tank circuit before the system shutoff valve.
Yes, the pressure tank can be displaced quite a distance from the pump; either by depth of the well or convenience of placement for the tank due to climate constraints.
If you're talking about a stock tank or other unpressurized system. The issue that matters is you have a level switch that works to turn the pump off. The constraint is the cost in running the pipe and power losses in the electrical cable are what would determine how far away the pump can be located.