What DOES distillation? I'm not sure what you mean, but distillation is used for purification of a liquid. You boil a liquid, and the liquid with the lowest boiling point will evaporate. The vapors are then run through a cooling coil, where they condense, and are collected in another vessel.
Hopefully this answers your question.