What is a substation and how does it work?