Question: How exactly is the interaction between two chiral compounds so they can tell the difference between S or R?

Answer: 
If the compounds have never been made before, then the enantiomers have to be separated prior to analysis. Then analytical and spectroscopic techniques must be used. The R and S configurations cannot even be assigned until the relative stereochemistry had been elucidated. This is usually done by specific NMR experiments. Chiral HPLC can be used to give enantiomeric purity.
The method used to determine whether a specific chiral molecule is the $S$ or $R$ enantiomer is determined according to the Cahn–Ingold–Prelog priority rules. The steps to this are:

1. Look at the four atoms directly attached to the chirality center, and rank them according to atomic number (1-4, 1 being highest ranking, 4 being lowest ranking). Isotopes of higher mass rank higher than lower mass isotopes.
2. If a decision can't be reached by ranking the first atoms in the substituent, look at the second, third, or fourth atoms away from the chirality center until the first difference is found.
3. Multiple-bonded atoms are equivalent to the same number of single-bonded atoms.
4. Having ranked the substituent groups, draw (or imagine) the lowest ranking substituent group away from yourself. The other 3 substituent groups will then appear to radiate out towards you. If a curved arrow drawn from the highest to second-highest to third-highest ranked substituent ($\ce{1->2->3}$) is clockwise, the chirality center is said to have the $R$ (for *rectus*, meaning right) configuration. Oppositely, if the curved arrow is counterclockwise, the chirality center is said to have the $S$ (for *sinister*, meaning left) configuration.