Counter is term for spells that have counterpart spell which dispels (cancels) it, and which it dispels. This means that both counter spells in a pair can not be active on the same unit at the same time. When a counter spell is cast on a unit which is under the effects of its counterpart, the existing spell effect will be removed and the newly cast spell will take effect.
Additionally, there are spell pairs that do not dispel each other and therefore are not true counter spells. However, their effect are equal and opposite and in that sense they cancel each other.