Power cutting out

I have a Polaris Sportsman 550 EFI,2011.

When I am in 2×4 H, along a dirt/rock road then go into a trail that is narrow, rocky, trees etc, I gear down to 4×4 low.

A couple minutes later and thruout the trail my machine just loses power and stops. I then just have to put it in park and turn the key to start up again.

I have 2 suggestions on why so far:

1- if I have extra keys on the key chain, the weight of the swinging of the key will turn the ignition off

2- something about the wires to the run/off switch.

Any other suggestions?