Using a dog crate for housebreaking and puppy safety when you aren’t around to observe him closely does not mean leaving the pup confined for long periods of time. If you do that, the puppy will be forced to eliminate in his space and over time will lose the urge to have a clean place to stay.
A good rule of thumb is not to leave a puppy crated for more hours than his age in months (up to 6 months). So an eight week old pup should not be left in the crate for more than two hours at a time, a 12 week old pup for three hours, etc. When the puppy is let out, immediately take him to the ideal elimination spot. When he does his business, give plenty of praise and maybe give a small healthy treat. Play with him for at least a few minutes before he has to be crated again, otherwise he will learn to delay eliminating as he doesn’t want to go right back to the crate.
Six hours is really the longest amount of time a young dog or an elderly dog should be asked to go without eliminating. A dog in his or her prime may handle eight hours with an occasional longer spell. However, holding the urine for long periods of time can increase the odds of a bladder infection. There are bound to be occasional accidents until your puppy matures and has longer urine retention. Do not scold the pup near the site of the accident, simply clean it thoroughly with an odor neutralizer such as PON.