Could also be a fuel tank venting problem. Drive around till problem occurs then pull over. Leave engine running and quickly remove gas cap. If you hear a big Whoooosh... you have a venting issue. A partial Vacuum builds in the Fuel Tank. Fuel pump pressure may read OK at idle, but can't maintain pressure under load, particularly on a Boosted car. ( You need to have a FP Gauge set up and readable in Real Time while driving under Load ).
When you shut the engine off, the gas tank will gradually pull air in from the gas cap, alleviating the problem for a short time. Improper deletion of Evaporative Canister ( Charcoal Canister ) system can be a major source of fuel tank venting issues. People may plug off the wrong Charcoal Canister lines and don't realize that they have just plugged off the Main vent line to the Fuel Tank.
Note: Emissions fuel caps are, for all intensive purposes, " Non-Vented " They will vent a small amount, but not nearly enough to prevent a vacuum from building in the Fuel Tank. Up to about 1971, Datsun used vented gas caps. Then they switched over to Emissions style starting around 1971 1/2.
You can also drive the car around with the gas cap loosened if you suspect a venting problem. If problem goes away then you have confirmed the issue. Obviously do this on a half tank or less and don't go throwing it around corners or accelerating hard. And carry a fire extinguisher!!