They were stills (sometimes called “distills”) being used to make alcoholic spirits.
While the science being used in those television programs was rather primitive, it was science nonetheless. And that’s where the history of distillation begins: with scientists.
Distillation is the separation of liquids that have different boiling points.
While alcoholic distillation is the best-known version, the process is also used to turn crude oil into more refined fuels, and even turn salt water into fresh water.
Some histories have the distillation process originating in Persia, at the hands of alchemists/chemists/physicians. The most famous, Jabir ibn Hayyan (also known as Geber), is also thought by some to be the father of modern chemistry. Although some scholars doubt the existence of Geber , it is known that there was work done on distillation in Persia in the eighth century.
There is also evidence that there was distillation of alcohol at The School of Salerno medical school in Italy around the 12th century. The following century, fractional distillation, where multiple liquids are separated, was pioneered there by Tadeo Alderotti.
Fast-forward to today, and nothing has really changed. Distillation still works the same basic way now as it did for Tadeo.