Most materials absorb light at some wavelengths. Unless they are 100 % efficient fluorescent material (which is impossible), some or all of the absorbed electromagnetic energy is converted to heat. When exposed to a laser light (very concentrated beam of coherent photons) of suitable wavelength, the material will absorb and generate enough heat to explode (ablation). By tuning various parameters (I guess size/shape of the solid material, energy density of the laser, etc) the exploded fragments can be nanosized.