Atoms are the smallest unit of an element that can exist independently or in combination form.
Molecules consist of atoms of elements covalently bonded to atoms of the same element or with atoms of different elements.
Elements are distinctive forms of matter consisting of atoms having the same atomic number (number of protons in their nucleus) ; elements have specific chemical and physical properties by which they can be recognised based on their atomic number.
Compounds consist of atoms of elements bonded together in fixed ratios; that have properties different than the elements from which they are composed; and can be seperated through chemical processes.
Mixtures consist of forms of matter in proximity that maintain their individual properties and can be combined in any ratio;and can be seperated by physical means.
The relationship is simple.
Atoms are what all matter are ultimately made up of. Atoms are the smallest units of an element.
Elements are substances composed of all the same type of atoms, and have specific chemical properties. Aluminum for example contains only Aluminum atoms, and no other, and has chemical properties specific to Aluminum.
Molecules are combinations of atoms that are not necessarily all the same element. Sometimes they are the same element, like air molecules. Air molecules are a mix of pairs of Nitrogen, and pairs of Oxygen. Although the pairs of atoms are the same element, they are more than one atom so they are molecules. Water molecules are made of Hydrogen atoms and Oxygen atoms, i.e. different elements.
Compounds are combinations of elements into new substances, like water. Water combines the elements of Hydrogen and Oxygen and has chemical properties distinct from the elements it's made of.