After reading your post, my first thought was that you are obviously not taking him outside often enough and not making sure he does his business when he is out there.
If he does not relieve himself, then he should be put in his crate, for a few minutes, and then straight back outside!
I would also start taking him every fifteen minutes. Yes, it is a lot of work, but clearly every 30 minutes to an hour isn't enough for him to understand the message. I might also take him to the Vet to rule out any medical issues, particularly with a male dog. If he has some type of infection, he would be entirely unaware of his "feelings" or ability to control it.
I am sure that he always goes first thing in the morning when you take him out. Praise, praise, praise that event. The next time you go to take him out, if he doesn't do anything, then put him in the crate for up to 5 minutes, no play or talk in between, and take him directly outside. Keep doing this until you see that he has succeeded in going potty outside.
Obviously if he doesn't go outside and then relieves himself in front of you within two minutes of coming back in, you didn't give him enough time outside to do his business. He is still quite young and one can't expect a dog to be reliably housetrained until one year of age. 16 weeks is 4 months old and that is quite young, especially for bladder control in certain males.
Every time he makes a mistake in the house, it is your
mistake. Pay it no attention and put him outside. The timing between potty breaks needs to be shortened, and you must be certain that he has done his business before going back inside. Capture the successes and ignore the failures.
Good luck and keep us posted.