Most variants of this kind make a certain amount of sense. Dan for Daniel, Mike for Michael, Sue for Susan, etc. But "Margaret" seems to have just started collecting weird, unintuitive variants and never bothered to stop. The wiki section on this is mind-blowing.
How did this come to be?
The English have been rather fascinated with rhyming names and rhyming slang for many hundreds of years. (See cockney slang).
Rob the Bob. Rich the Dick. Meg the Peg. Will the Bill.
Its something so strikingly English its almost beyond any explanation but that. I'm looking for a solid source here, but all I can find are Wikipedia articles on rhyming slang.
Would Dick for Richard also be included? Im interested in that as well.
Well, Margarita is Latin for Pearl, which is another legit nickname for Margaret... can't vouch for the others, but mankind does appear to have an impressive ability to nickname each other.
This isn't a strictly historical question, but every language I know uses these domestic or short name forms. For example the Russian name Dinitry has these forms: Mitya, Mityay, Mit'ka or Miten'ka, Dima, Dimka, Dimochka, Dimulya, Dimusha.