It goes beyond whitespace: merging duplicate selectors, collapsing longhand into shorthand, shortening colours (#ffffff to #fff), removing overridden declarations and reordering rules where the cascade allows. That typically doubles the savings versus whitespace-only minification.
When should I turn structural optimisation off?
When you are minifying a fragment rather than a complete stylesheet. Reordering is only provably safe if the optimiser can see every rule that participates in the cascade. If your snippet will be concatenated with other CSS, disable it.