Active noise cancelling does mean that the headphones create a sound wave which has the same frequency but is out of phase by a single wave length. This causes destructive interference which causes the total energy of the waves to equal zero. You are partially correct but active noise cancelling has the same effect as putting earplugs in due to wave mechanics.
https://en.m.wikipedia.org/wiki/Wave_interference