How can I move the handlebars on a mountain bike close to the rider without affecting handling and control?
Moving your bars is probably going to move your centre of gravity which is likely to affect the handling of the bike. That said if the only change is that your elbows are more bent it might not make a big difference.

A shorter stem will move your weight backwards that means:


The bike will be more stable and less twitchy.
It will be easier to move your weight back when descending. It will also increase your range of movement, giving you more control (as long as you use it!).
You will be in a less powerful position for pedaling.
The front is more likely to unweight and rise when going uphill. 


If you're fitting a shorter stem you'll want to lift the bars up as well, you can do this by fitting a stem which is angled, or riser bars, or both. This is all about what feels good so you'll want to experiment a bit - long/low and short/high both feel good, long/high and short/long don't.

The other thing you can do to get yourself closer to the bars is to move your saddle forwards - the saddle can move forwards or backwards on the clamp, and you could possibly use a seatpost with less/no layback.