A very simplified version of laser mechanics; the laser produces a beam of light energy that is coherent and collimated. That means the light is all the same wavelength and it is focused into a fine beam.
The various lasers used in dentistry are usually identified by the resonating material such as Yag, diode, chromium, CO2 or Alexandrite. This material is what determines the wavelength of the laser.
Different wavelengths of light energy are absorbed by different substances. For example some wavelengths are absorbed by water and some wavelengths pass right through water. If a substance absorbs the laser energy it will immediately take on the energy of the laser, usually as heat. The rapid heating of the tissue is what causes the changes we see with a laser.
Each wavelength will effect the tissues in quite different ways. For example a diode laser is absorbed by dark colors such as hemoglobin. That makes it ideal for cutting soft tissue but it will have no effect on tooth structure.
It is possible to focus the laser energy into a very narrow band so that it effects the tissue practically on a cellular level.