A rotary evaporator looks like a complicated scientific instrument, but the process and using the system is straight-forward. The principle is based on basic chemistry, mainly, once liquid is heated to boiling, it turns into vapor or gas and once this gas cools, it converts back to liquid.
In rotary evaporation, you place a sample in a flask, then heat the sample in a system that is under vacuum. The vacuum is needed to decrease the boiling point of the liquid sample by reducing the pressure, so that the sample can boil at a lower temperature (say 40°C instead of 100⁰C). Because you need less heat to boil your sample under pressure, you can treat your liquid more gently. This helps preserve more flavors in your sample.
Back to the process. As the sample is heated, the liquid transforms into vapor, which leaves the flask and enters the condenser. The condenser is cooled by water or by a chiller. As the vapor cools in the condenser, it turns back to liquid form, which collects in a separate receiving flask. The liquid in the receiving flask is called a distillate and ideally contains your alcohol plus intense flavors of whatever else you put in the sample (berries, teas, herbs, spices, etc.).