Moles are a unit of measure used to convert between different quantities like grams, molarity or volume.
Dimensional analysis is doing math with units. They multiply, divide and cancel out just like numbers. This is why like for area of a rectangle: 2m × 3m = 6m² is in units of distance squared and volume is in units of distance cubed.
Example Chemistry question.
Now, say you have 10 grams of NaCl salt that is added to 1 L water and you want to know the concentration. You would look at the periodic table and find the atomic mass of both Sodium (Na = 23 g/mol) and Chloride (Cl = 35.5 g/mol).
Once you have the atomic mass of both elements add them together to get the atomic mass of the compound NaCl = 23 g/mol + 35.5 g/mol = 58.5 g/mol
set up the multiplication so that grams cancels out during multiplication. Like so ....
Grams cancel leaving moles NaCl. The concentration of the solution, molarity = moles/liter
Divide 0.17 moles NaCl by 1 Liters = 0.17 Molarity NaCl
Hope this helps, let me know if you have any questions.