If your battery isn't getting charged, the first thing to have checked is the battery itself.
If that tests good, then you need to see what the voltage at the battery is when it is running.
Should have between 13-14 volts at wide-open-throttle. If you don't have that, then you know the charging system is bad. There may be different things wrong with the system from there, from coils, to loose wires, to the stator. There are plenty of YouTube videos on how to check various things and how
the charging system works.
Rattosh51
YT6800