Answer:
By definition, a molecule is a group of atoms bonded together. This means that it can be a mixture of two separate atoms (e.g. atom A and atom B bond together to make molecule AB). Molecules with two or more separate elements are called compounds.
Molecules can also be made of more than one atom of the same element (e.g. atom A bonds to another A atom to make molecule AA). This is not called a compound because they are not different elements.