It's not your breathing technique that's the issue. Take more breaks as you ride! Your lungs are already running full speed to keep up with your muscle effort!
Ride a little slower if you don't feel like stopping, but take a "break" of some sort. When I get beyond my lungs' ability, I get off the bike and walk a bit. My lungs get stronger as I get stronger, and I need fewer breaks as I go on.