He might hide it because he doesn't fully understand his own fascination. Harry has always been on the side of good, but perhaps there are elements of the dark side that seem alluring in a strange way. He could be afraid that exploring these feelings would lead him down a dangerous path, so he keeps it a secret.
The plot could develop with Harry secretly studying dark magic texts in the restricted section of the library. He might start to have strange dreams or experiences related to the dark magic he's exploring, and he has to be very careful not to get caught by Filch or the teachers.
Maybe the writer wants to be different and create a shock factor. By making Harry a dark wizard, it goes against the common perception and grabs attention.
In the 'Harry Potter Hides He Is Dark' fanfic, Harry could be hiding his dark side by carefully choosing his words. He wouldn't let slip any thoughts or opinions that might hint at his darker tendencies. He might also avoid certain places or people that could trigger his dark side, like staying away from dark magic artifacts or those who practice dark magic openly. And, of course, he could be using Occlumency not just to keep his thoughts private from Voldemort but also to hide his own dark nature from others.
The revelation of Harry being 'dark' would cause chaos in the wizarding world. People who once idolized him would feel betrayed. The Order of the Phoenix might question their support for him. Enemies could use this as an opportunity to turn the public against Harry. His relationship with Ginny would also be severely strained. She fell in love with the 'good' Harry, and this new side of him could be too much for her to handle. Also, it could potentially put Neville or Luna in danger if they continued to support Harry, as they might be seen as associated with his 'darkness'.
One possible reason could be that in the fanfic, Harry discovers Snape's deeper motives earlier. Maybe he stumbles upon Snape's memories or has a series of interactions that show Snape's true loyalty to Dumbledore and his complex role in protecting Harry all along. This new understanding makes Harry admire Snape.
One possible reason could be that in the fanfic, the author might twist the story to make it seem like his parents' actions had unforeseen consequences that affected Harry negatively. For example, their fight against Voldemort led to Harry being an orphan and having to bear a great burden from a young age.
One possible reason could be a misunderstanding. Maybe Lupin did something that Harry misinterpreted as betrayal or negligence. For example, if Lupin was forced to keep a secret from Harry for his own safety, but Harry found out in a way that made him feel deceived.
Perhaps in this fanfic, there has been some major plot twist that makes Harry believe that bowing to Voldemort is the only way to save his friends or the wizarding world. For example, Voldemort may have threatened to kill all of Harry's loved ones if he doesn't submit, and Harry is sacrificing his pride for the greater good.
One reason could be the strict control by the official copyright holders. They might be worried about fanfic diluting the official brand or misinterpreting the original story. Another factor could be some fans' purist view. They only want to stick to the original works by J.K. Rowling and consider fanfic as something not in line with the 'true' Harry Potter universe.
One possible reason could be a misinterpretation of his character. In the original series, Harry Potter doesn't hate Muggles at all. But in this fanfic, perhaps the author wants to explore a 'what if' scenario where something drastic has happened to make him have such feelings. Maybe he's been betrayed by a Muggle - in the fanfic world, this could be a made - up situation that sours his view on all Muggles.