Staying in

Okay so this is hard for me to post cause I'm not one for sharing things so personal but I really need help. So me and my fiancé have been having trouble with him staying in me. Like when we go to have sex his dick doesn't want to stay in me. And then  he losses confidence which turns the whole night into a loss with no pleasure for either of us. I'm open for tips and curious if any other couples have this problem.