A Tesla coil is a device invented by Nikola Tesla for producing ridiculously high voltages and lots of sparks.
The device operates by ‘magnetic induction’. A changing electric current in one coil – called a primary coil – creates a changing current in a second coil – called a secondary coil. This achieved because the first coil creates a changing magnetic field, and the second coil is immersed in that changing magnetic field.
This is just the same principle that is used in a transformer that is present in most domestic electrical items.
In a transformer the ratio of the number of turns of wire on the primary and secondary coil determines the ratio of the voltages and currents in the two coils. For example if the primary coil has 1000 turns and the secondary coil has 100, then 240 V alternating current in the primary will create just 24 V in the secondary. This component reduces mains voltages to safe levels domestic equipment.
In a Tesla coil there are two differences from a normal transformer. The first is that the primary coil typically has a small number of turns (perhaps only 1), and the secondary has thousands. Thus 240 V in the primary will create perhaps 240,000 V in the secondary. The second is that voltage changes are made very quickly which increases the secondary voltage even more.
In fact such coils are more complicated and employ several tricks to make them even more lethal.