Hi
Here's some information that should help determine why your battery isn't charging properly:
"Your Mac notebook computer may not be charging because of a high performance level, the software, or Battery health settings.
- Avoid draining the battery quickly: Your computer may be running at a very high performance level that uses more power than the power source provides. For example, some apps—such as video editing software and video games—can require more power and drain the battery more quickly. Connected devices, and settings such as brightness, can also drain the battery. See Save energy on your Mac.
- Update the software and firmware: In some cases, software or firmware updates might be available for your computer that improve communication with your power adapter. See the Apple Support article Update macOS on Mac.
- Reset the SMC: Reset the System Management Controller (SMC), which controls how your Mac manages power. If you have a Mac with Apple silicon, just restart your computer. For other Mac computers, see the Apple Support article Reset the SMC of your Mac.
- Turn off battery health features: It’s normal for your Mac notebook computer to stop charging before 100% to optimize or extend the lifespan of the battery. You may be able turn off these features in Battery settings. See If your Mac battery won’t charge completely."
You can find additional troubleshooting in the full resource here: If your Mac battery won’t charge
If things persist you can reach out for Additional support here: Get Support
Take care.