The "Harry Potter Universe" is a collection of specific characters and specific locations. That is what's protected by copyright. You can totally make your own original story about a boy wizard, a school for magical people somewhere in the Scottish Highlands, and so on. You can totally repeat the "vibe" if you like, provided you don't base it on the specifics of Harry Potter.
To give some concrete examples:
Sherlock Holmes (and the "Sherlock Holmes Universe" if you like) used to be protected by copyright. While it was, there were thousands of competing books about detectives, including Maigret (with his distinctive pipe and overcoat, really rather a lot like Holmes), Miss Marple, Poirot, Lord Peter Wimsey, and so on. "The vibe" of detective fiction was very much not copyrightable.
Furthemore, Dracula was a specific book, and certain works like Nosferatu did copy it. However the "vibe" of Dracula is vampires, and vampires are ancient folklore. There have been countless works of vampire fiction not infringing on Dracula's copyright. They just didn't copy Dracula. It's not that hard to do.
Musicians can copyright the melody and lyrics of their music, but they can't copyright the harmony, rhythm, and arrangement. If they could, we just wouldn't have music. An entire genre - blues - uses the same chord progression to produce hundreds of thousands of unique songs, but all within the basic structure. They are not copying each other, they're following the rules of a genre -- a "vibe". You can't copyright a vibe.