Close Before = Close After
The closer the bar is to your legs before contact in the snatch or clean, the closer it will naturally stay after contact, just like a ball bouncing.
Make this happen by:
Controlling your pulling posture to avoid tipping too far over the bar;
Making sure you’re balanced evenly over the whole foot through the pull;
And using your lats to keep the bar as close as possible without dragging all the way up.
The primary exception to the rule of “closer before, closer after” is when the bar is pushed too far back relative to the feet up into the hips—in that case, it will be pushed forward as the hips move forward during extension.
So the more complete rule is: closer before, closer after… as long as your body and the bar are positioned and balanced properly before.
And yes, you can counteract the bar bouncing forward with the upper body… to a degree. There are limitations to it, but more importantly, remember that the more of your effort is putting horizontal force into the bar, the less is going into upward acceleration, which is counterproductive.
In other words, the solution isn’t doing more with the upper body, but doing the lift better before that point. The pull is your primary control of the bar path, and the pull under is secondary and additive, not a substitute.