Maybe Sirius gets help from some powerful wizards or witches who believe in his innocence. They might testify on his behalf in front of the wizarding authorities. Sirius also could show his strong emotional bond with Harry. He has always been there for Harry in spirit, and now he can be there physically to raise him, which convinces the authorities to give him custody.
Sirius has to figure out how to give Harry a normal childhood while also training him in magic. He can't just let Harry be unprepared for the wizarding world, but he also doesn't want to push him too hard. Also, he may face financial difficulties. Raising a child isn't cheap, and he might have to find ways to earn money while also taking care of Harry.
If Voldemort gets custody of Harry in fanfiction, it would be a huge deviation from the original story. Harry would probably be exposed to a lot of dark and cruel things. Voldemort could try to break Harry's spirit and make him abandon his values. There might be a struggle within Harry between the good he has been taught and the evil that Voldemort represents. And the wizarding world would be in even more chaos as Voldemort would have more control over the one person who was seen as the hope to defeat him.
Perhaps James has more resources to take care of Harry. He could have a better living situation, more financial stability, or a stronger support system. In fanfiction, this can be a way to create a new dynamic for the characters, with James being the sole provider and protector for Harry.
The plot could develop with Voldemort trying to use Harry to open the Chamber of Secrets again, believing that there are secrets within that could enhance his power further. Harry, on the other hand, might find allies among the Death Eaters who are not fully loyal to Voldemort and use them to create a revolt from within. Also, Dumbledore and the Order of the Phoenix would surely be trying to rescue Harry, which could lead to many intense battles and rescue attempts.
There may be such fanfiction in some niche corners of the internet, but this goes against the original nature of the Harry Potter series and is also a rather strange and inappropriate concept. J.K. Rowling's original works don't have any such plotlines, and most official and mainstream interpretations stay true to the original characters' relationships and story arcs.
Yes, there might be such fanfiction out there in the vast world of fan - created works. However, this kind of story often takes a rather unorthodox and perhaps controversial approach to the characters. Fanfiction can cover a wide range of themes and interpretations, but this one is likely to be quite different from the typical Harry Potter stories we know.
One reason could be Harry's impulsiveness. Harry often jumps into dangerous situations without thinking, and Sirius, being his godfather and having a protective nature, would shout at him to make him realize the risks. For instance, if Harry decides to go after a Death Eater alone.
One major problem is that it goes against the nature of the relationship between Sirius and Harry in the original 'Harry Potter' series. Their relationship is more of a mentor - mentee or a father - son like bond, not a romantic or sexual one.
In a 'Harry Potter in a Custody Battle' fanfiction, it might be that Harry's muggle relatives and the wizarding community are in a custody battle. The Dursleys could claim they've been taking care of Harry all these years and have the right to keep him. But the wizarding world, like Hogwarts professors, might argue that Harry belongs with his own kind where he can learn magic and be safe from the threats only the wizarding world understands. There could be courtrooms filled with magic spells and arguments about what's truly best for Harry.
Well, it could be about Harry Potter getting into a battle to gain custody of something or someone. Maybe it's about him fighting for the custody of a magical creature or even a young wizard in need of protection. He might use his magic skills and the support of his friends to win the custody battle in this fan - made story.