Backstory at the Beginning of a Book
Part of why this method worked with Harry Potter is because things were actually happening. It wasn’t just exposition dumped into the reader’s lap by a narrator or any number of POV characters. If you can do that, it’s probably fine.
However, I also think it’s important to consider just how much this information matters at the beginning of the story. Is it necessary for your reader to understand how this world came to be before they start reading? Consider The Hunger Games, for example. We don’t learn about how Panem came to be before the story even starts. In fact, we get only limited details about Panem’s history as the three book series progresses. Mary E. Pearson’s Remnant Chronicles is another example. We never really learn what happened to North America and the rest of the world. We only learn the more recent history of the kingdoms occupying North America in the future, and even then, it’s not all presented in the beginning of the story. It’s woven in throughout the story as it unfolds.
Most of the time, it’s better for your reader to learn along with the MC or for the narrator/POV character to simply fill the reader in on important details as the story goes on, but ultimately it’s up to you. Follow your gut. 🙂