What exactly is voltage?
Your teacher was right.

Current is electric charges (usually electrons) moving.  They don't do that by themselves for no reason, no more so than a shopping cart moves across the floor of a store by itself.  In physics, we call the force that pushes charges the electromotive force, or "EMF".  It is almost always expressed in units of volts, so we usually take little shortcut and say "voltage" most of the time.  Technically EMF is the physical quantity and volts is one unit it can be quantified in.

EMF can be generated several ways:

Electromagnetic.  When a conductor (like a wire) is moved sideways thru a magnetic field, there will be a voltage generated along the length of the wire.  Electric generators like in power plants and the alternator in your car work on this principle.

Electrochemical.  A chemical reaction can cause a voltage difference.  Batteries work on this principle.

Photovoltaic.  Crash photons into a semiconductor diode at the right place and you get a voltage.  This is how solar cells work.

Electrostatic.  Rub two of the right kind of materials together and one sheds electrons onto the other.  Two material that exhibit this phenomenon well are a plastic comb and a cat.  This is what happens when you shuffle across the right kind of carpet and then get a zap when you touch a metal object.  Rubbing a balloon against your shirt does this, which then allows the balloon to "stick" to something else.  In that case the EMF can't make the electrons move, but it still pulls on them, which then in turn pull on the baloon they are stuck on.

This effect can be scaled up to make vary high voltages and is the basis for how Van de Graaff generators work.

Thermo-electric.  A temperature gradient along most conductors causes a voltage.  This is called the Siebeck effect.  Unfortunately you can't harness that because to use this voltage there is eventually a closed loop.  Any voltage gained by a temperature rise in part of the loop is then offset by a temperature decrease in another part of the loop.  The trick is to use two different materials that exhibit a different voltage as a result of the same temperature gradient (different Siebeck coefficient).  Use one material going out to a heat source and a different coming back, and you do get a net voltage you can use at the same temperature.

The total voltage you get from one out and back, even with a high temperature difference is pretty small.  By putting many of these out and back combinations together, you can get a useful voltage.  A single out and back is called a thermocouple, and can be used to sense temperature.  Many together is a thermocouple generator.  Yes, those actually exist.  There have been spacecraft powered on this principle with the heat source coming from the decay of a radio-isotope.

Thermionic.  If you heat something high enough (100s of &deg;C), then the electrons on its surface move so fast that sometimes they fly off.  If they have a place to land that is colder (so they won't fly off again from there), you have a thermionic generator.  This may sound far fetched, but there have also been spacecraft powered from this principle with the heat source again being radio-isotope decay.

Electron tubes use this principle in part.  Instead of heating something so that electrons fly off on their own, you can heat it to almost that point so that they fly off when a little extra voltage is applied.  This is the basis of the vacuum tube diode and important to most vacuum tubes.  This is why these tubes had heaters and you could see them glow.  It takes glowing temperatures to get to where the thermionic effect is significant.

Piezo-electric.  Certain materials (quartz crystal for example) generate a voltage when you squeeze them.  Some microphones work on this principle.  The varying pressure waves in the air we call sound squish and squash a quartz crystal alternately, which causes it to make tiny voltage waves as a result.  We can amplify them to eventually make signals you can record, drive loudspeakers with so you can hear them, etc.

This principle is also used in many barbecue grill igniters.  A spring mechanism whacks a quartz crystal pretty hard so that it makes enough of a voltage to cause a spark.