What a goober! lol. I knew a horse that was like this. His name was Captain and he unlocked his stall, let some buddies out and went into the feed room and ate the grain. He coliced really bad from that, too. The owner noticed that when he turned the lights off on his front porch to go to bed, Captain would immediately open his door
The owner ended up finding a special kind of lock that Captain couldn't unlock. He hated doing it, like in case of a fire or an emergency. So I really can't tell you anything else but to keep trying different locks.....sorry.

These horses are tricky!