Jupiter was the king of all the gods. Mercury was his youngest son. Mercury's mother was Maia.
Mercury had many talents. He could fly faster than most of the other gods, partly because of his winged sandals. He was also trustworthy. He was playful enough to be interesting. He was very bright and very loyal. He was the best negotiator in the world. He was always cracking deals to get himself and others out of trouble. He was the god of trade, commerce, and travel.
Unlike his half-brother, Mars, the god of war, whom almost none of the other gods liked very much, Mercury was very popular in the ancient heavenly world. Even Mars trusted him. For that matter, even Jupiter trusted him. Jupiter was always sending his youngest son, Mercury, off to fix some problem or other. And Mercury almost always found a way to fix thing in a way that did not trouble Jupiter at all.
Mercury did not show up in Roman mythology until Rome was a Republic. Mercury was not a god when Rome was a kingdom. That tells scholars that Mercury's personality, myths, and abilities were probably copied from the ancient Greek god Hermes, during the time of the Roman Republic, and then became a very important Roman god on his own.