Diagnosis
Yeah, this one's common on new units. The fuel tank cap isn't venting properly, creating a vacuum that starves the engine of fuel after it burns through what's in the carburetor bowl.
How to Fix It
First, try running it with the gas cap slightly loose. If it runs fine that way, you've confirmed it. The fix is usually simple: remove the gas cap and check the small vent hole in the center of the plastic cap. Poke a thin wire or a paperclip through it to clear any manufacturing debris or blockage. You should hear a slight hiss of air when you open the cap on a warm engine if it's venting correctly.
If That Didn't Work
If the vent is clear and it still dies, the problem might be a stuck or gummy float valve in the carburetor from old gas or factory preservative oil. You'll need to remove the carburetor bowl (single bolt on the bottom), clean the bowl and the small needle valve the float controls, and reassemble.
Heads Up
Always use fresh, ethanol-free gas if you can find it. The ethanol in standard gas attracts moisture and turns to varnish surprisingly fast in small engines, causing these kinds of fuel flow problems.