I imagine GameFreak sits down (figuratively) with each Pokemon, and decides what moves will best complement their design, their type, and their characteristics.
By Characteristics, I mean things like Stunfisk probably gets Camouflage because, according to its White pokedex entry:
>It conceals itself in the mud of the seashore. Then it waits. When prey touch it, it delivers a jolt of electricity.
But in general, it would be something a long the lines of "it's a Water type, so let's make it compatible with Surf" or "it has a tail, let's make it learn Iron Tail". I think the process would be something along those lines, anyway.
But, even so, there are still some moves that some Pokemon can learn that I have never understood. Things like Rhydon learning Surf, a move which it is 4x weak to, is case and point. Blastoise with Dragon Tail, as you mentioned is another odd choice, considering that Blastoise's tail is absolutely minuscule. But for these instances, I can only answer with: Game Freak logic.
No, I have no sources or anything, since I am basically thinking this up on the spot.