What you are looking at is known as the Dzhanibekov effect or the tennis racket theorem or the intermediate axis theorem.