There's no "one way" to do it. It doesn't have to be in a bed, although that's most common and comfortable. Most men are already erect before they get into bed simply because of the excitement. There can be foreplay if you're into it. When the man is erect, then things get jiggy.
Honestly, I've never heard of a man not being able to orgasm while hard. In my opinion, it sounds a little strange that you can't do sexual things while you're hard. You can't have sex if you aren't hard, because your penis won't be able to get in. It might be worth seeing a doctor about it.
Sex happens naturally a lot of the time. There isn't a step-by-step process. It's different every time. When it happens for you, you'll just know what to do and when. Try not to overthink it as that can kill the mood.