He's testing you. It's impossible to tell you what to do on here, without seeing what he does, the best thing to do would be get a good instructor to help you You don't want any accidents, as this pony sounds (from your other posts) like it isn't for a beginner Or ask an experienced friend.
he is napping to the gate to get out of work. This needs to be stopped immediately. If you cannot do this then do not ride him as it will get worse to the point pony will become dangerous
Definitely get some lessons this is what my old pony would always do. As soon as i got some lessons it boosted my confidence and after a month my pony stopped doing it all together. It is the best solution.