Note that "Planetary Nebula" is a poor name for the phenomena. It's a type of nebula with a star in the center. Early on in astronomy, people were reminded of planets by the round shape.
Planetary nebula - Wikipedia