I have seen this when the battery is past its life expectancy. The battery swap is very easy, and the replacement batteries are plentiful (on eBay). I have done it a number of times!
I just replaced my battery in my Surface Pro 4. I followed an online replacement video that wasn't iFixit. Now my surface doesn't charge or power on. Reading some comments from others that are looking at the same problem after they changed their batteries, there appears to be a problem with Microsoft using a "Zero Ohm" resister that can be taken out by just lifting the board to remove the old battery. iFixit's video that shows removing the whole motherboard, I think that would have eliminated the problem I am now facing. Something should have been noted with the replacement battery that iFixit supplies, recommending that the entire motherboard be re-moved would have helped in avoiding this potential failure. I am onboard with the whole concept of 'Right To Repair', and the number of people that commented on the iFixit site that had the same scenario problem, makes me think that iFixit wasn't quick enough to acknowledge the problem or simply recommend with a note supplied with the replacement part.