Perhaps there may be an issue with some connector, or charging cable; or if there is an interruption in the process.
These articles cover several areas in general, may have suggestions you've not tried.. Or tried, when not needed.
• Get help with your Mac notebook battery - Apple Support
//support.apple.com/en-us/HT204054
• If your USB-C power adapter isn't charging your Mac notebook - Apple Support
//support.apple.com/kb/HT204652
• Determine battery cycle count for Mac notebooks - Apple Support
//support.apple.com/kb/HT201585
Depending on the physical age of your product, and the chemical age of battery,
there may be a variance in performance. Keep an eye on battery life, & use-Cycles.
..The portable Mac can be left plugged-in and it will not overcharge..
The battery will not see much loss or increased cycle-count, if left on AC adapter.