I believe this happens if and only if the class number is odd. For an ideal class to have this property it must be represented by an element of the form $I/\bar I$, where $\bar I$ is the Galois-conjugate ideal. Since conjugation is inversion in the class group, this means that the ideal class is a square. If all ideal classes are squares then the squaring map is surjective, hence injective, and so the 2-torsion subgroup is trivial. So the group has odd order. As for your question of how often this happens, the 2-part of the class group is related to the number of primes dividing the discriminant. If, for example, there are at least 2 odd primes $p, q$ dividing the discriminant of $K$, then the 2-part is non-trivial. Indeed, the unique ideal above $p$ is 2-torsion in the class group of the maximal order, but not principal. (And the class number of any sub-order is a multiple of $h(\mathcal{O}_K)$ so it fails for the orders as well). But if $K$ has prime discriminant then indeed the class number is odd.