You are probably triggering herding responses. He would control cattle with barking and teeth. I would not play this game, for him it is not a game in the same sense as you see it.
You cheat. Pick up the ball and throw it or drop kick it over his head. If anybody blows the whistle, scrag the ref.
NOTE: You might be well-advised to take it easy until he's over a year old. Knowing that I'm a hiker, our breeder was quite strict with me: no big physical challenges until 1 year old. You don't want growth-plate injuries in the wrist (the injured bone will fuse a stop growing; the other will continue, and you get a curved foreleg). I don't know if pups are more susceptible to CCL injuries.
Al got some wicked blister flappers on his pads -- like dime-sized, thick flappers peeled off -- wet pavement -- looked bad but healed uneventfully in less than a week.
Soccer has always been Al & Gwynnie's favorite game, second only to killing the vacuum cleaner or the garden hose. I'm good at kicking the ball over them. If you kick the ball and it hits the dog before the first bounce, that's a personal foul.
Al kicks the ball into the air on the tip of his nose, like a trained seal; his record is 8 consecutive times without letting it touch the ground.
It's hysterical with little kids at the playground who aren't so good at throwing or drop-kicking: the corgis corner them.
We have a paved playground area, suitable our mostly wet Seattle weather. Fast soccer surface. Al will dribble the ball around and around all on his own. He doesn't need me.
He is also excellent at passing the ball back to me. His aim is right on, although he's never learned to compensate for gravity or wind.
Al almost never barks, but when I kick the ball high and he chases it, he always barks sharply when he gets it. He barks at the ball, not me.
Neither of ours has ever shown any nipping behavior. Don't allow that.
Have you taught him sit/stay? If you make him stop/sit/stay whenever he barks objectionably at you, this will not be fun and maybe he'll learn not to bark.
Thrift stores are a good source for recreational pneumatic spheres.
It's really fun to play "catch". Maybe start with a lighter ball, like a water polo ball. When Al is 3-5' away from me, I lob the ball gently at him, and he kicks it back to me with the tip of his nose (you'd think this would hurt).
Never use a basketball; too heavy; I'd fear a neck injury.
Anna is correct. Corgis are heelers, that is to say, they nip at the heels of the cattle or sheep to try and control them. I'd try to control the pace of the game so it doesn't become too rough or frenzied and also, as John noted, you don't over do it and cause an injury to still growing joints.