Cloth fibres are bound together by chemical bonds, the polymer strands becoming fixed in unnatural shapes (wrinkles) as the fabric bends.
These bonds are weakened by heat, so when a hot iron is applied, the cross-linking between the fibres is loosened, allowing the weight of the iron to force them into a new, flatter shape.
As soon as the heat is removed, the polymers re-bind into their new position and, voila, a freshly pressed shirt, skirt or pillowcase. Apply weight without heat and the job is much harder unless water is added too – hence the wrinkle-busting power of the steam iron.
Plus, take a look at: