The short answer is that they don’t. the longer one is that they do, and the contact between atoms is given by the zerom sum of attractive and repulsive forces between atoms. That means that if you bring two atoms close enough they are in contact if the attractive force between them is the same as the repulsive one. At a certiain point, fi you bring atoms together, they with act on each other through those two forces.
Beyond that contact point, if you could push the atoms more together they start repelling each other. Without adding a lot of energy into binding the two atoms together you won’t be able to mix them into a molecule. You may need a chemical reaction to occur in order to bind them together, but that is beyond the contact point.
So, in short words, on a macro level object do touch each other, but on atomic level atoms touch each other via the attractive and repulsive forces. Basically, your atoms will never touch the atoms of a table as there are forces between your hand and the table that will push you back.