One reason could be disillusionment. Maybe he discovers that the wizarding world is not as noble as he once thought, with a lot of hidden political intrigue and corruption. For example, the Ministry of Magic might be misusing its power, and Harry, being a symbol of justice, can't stand it anymore.
Maybe he thinks it distorts the real story of the wizarding world he knows. Fanfictions often take creative liberties that might go against his own experiences and the original narrative.
It could be that Harry has faced so many challenges in the fanfiction that he's simply burnt out. Just like in real life, if a person endures too much stress or hardship, they might want to step away. In the fanfiction, Harry may have reached his limit of what he can handle in the wizarding world.
In certain fanfiction scenarios, Harry could leave the wizarding world to explore other magical realms or non - magical places. He may feel that his growth and understanding of magic and life are restricted within the wizarding world he knows. Maybe he meets a group of people from outside the wizarding world who offer him a new perspective and a chance at a different kind of life.
Some of Harry's friends could also be antagonists in this fanfiction. They might not understand his reasons for wanting to destroy the wizarding world and try to stop him. For example, Hermione, with her love for knowledge and the wizarding world's institutions like Hogwarts, would probably try to reason with Harry and, if that fails, might even fight against him to protect the world she loves.
It could also be a story where Harry has lost all hope. He has seen too much death and destruction in the wizarding world, from the war with Voldemort. He might think that the only way to end all the pain and suffering is to just end the wizarding world as it is. He could start by attacking the key institutions like Hogwarts and the Ministry of Magic.
In fanfiction, Harry Potter can change the Wizarding World in many ways. For example, he might introduce new spells or magical concepts that were not in the original series. He could also have different relationships with other characters, which in turn would affect the social dynamics of the Wizarding World.
Some might be angry, thinking he's abandoning his responsibilities. The Ministry of Magic might try to persuade him to come back or even use force if they thought it was necessary for the safety of the wizarding world. His friends, on the other hand, would likely be sad and try to understand his reasons. They might also try to convince him to return, as they know how much he means to the fight against evil in the wizarding world.
Perhaps he feels betrayed by the wizarding world. Maybe some of his friends turned on him or the institutions he trusted failed him. For example, if the Ministry of Magic wrongly accused him again, it could push him to abandon it all. He may also be haunted by the many deaths he witnessed and feels that leaving is the only way to escape the painful memories.