One example could be if they plagiarized fanfiction works. Taking someone else's story and passing it off as their own within the fanfiction context is a big betrayal.
Maybe they started a negative campaign against fanfiction, saying it was a waste of time or not a legitimate form of writing. This would go against the essence of fanfiction which is a creative outlet for many fans. They could also have used fanfiction works for commercial gain without proper authorization from the original creators, which is also a form of betrayal.
Some fanfictions might have Misty betray Ash. Perhaps she gets lured by the promise of power or some valuable reward. She could be tricked into believing that Ash is no longer the friend she thought he was and that betraying him is for the greater good.
In certain fanfic ideas, Arceus could be influenced by an evil force. This evil force manipulates Arceus into believing that Ash will cause great harm in the future. So, Arceus betrays Ash as a preventive measure, according to the fanfiction plot. However, this is just a fictional concept and not part of the official Pokémon storyline.
A fellow trainer in Alola could betray Ash. This trainer might be envious of Ash's success as a champion. He could secretly work with Team Skull or some other antagonists to undermine Ash. For instance, he might give false information to Ash about a battle location, leading Ash into a trap.
Maybe Team Rocket. They've been after Ash for a long time. If Ash comes back as a champion, they might see it as a threat and betray him in some way. They could pretend to be his friends at first and then stab him in the back to get what they want, like his powerful Pokémon or his championship title.
His rival could be the one to betray him. Rivals are often jealous and competitive. If Ash's rival saw an opportunity to gain an advantage by betraying him, they might do it. For instance, they could lie about Ash to the Pokémon League, getting him disqualified from important battles.
It could be Gary. Gary has always been a rival to Ash. Maybe in this fanfiction, Gary gets jealous of Ash's progress and decides to betray him by making false accusations to the Pokemon League about Ash using illegal training methods.
Gary Oak is a likely character. He has always been a rival to Ash and in fanfiction, he might betray Ash out of jealousy or a desire to be the ultimate Pokémon trainer. Another could be Misty. Maybe she gets influenced by some external force or her own insecurities and turns against Ash. Brock could also be a candidate in some stories. If he falls in love with a girl who has a vendetta against Ash, he might be forced to choose between his loyalty to Ash and his new love interest.
In certain fanfictions, a Pokémon professor or an authority figure in the Pokémon world could betray Ash. They may have their own secret agendas. For example, a professor might use Ash's research data without his permission or manipulate him into dangerous situations for their own experiments. This would make Ash feel extremely betrayed as he looks up to these figures for guidance.
His rivals could be the ones to betray him. For example, Gary Oak might see Ash's godlike powers as a threat to his own status and decide to plot against him. Gary could spread false rumors about Ash to turn others against him.
In fanfiction, Gary could be a likely character to betray Ash. He has always been a rival and might have ulterior motives. For Dawn, Zoey could potentially betray her. Zoey has been a tough competitor and might be jealous enough to take some underhanded actions. Another possible betrayer for Ash could be Team Rocket. They've been after his Pikachu for a long time and could use betrayal as a new tactic. For Dawn, perhaps a new coordinator who is envious of her popularity in the coordinator world.