I'm also not the biggest expert in iOS to know why this specific API works differently on different phones.
Well, this is not a critical issue. Your app works great anyway, thanks a lot!
P.S. probably old phones are not properly supported by Apple... No need to find bugs in old versions of iOS, to adapt old phones to new versions of iOS ))
From other side, apps like already mentioned Life360 reporting "charging" always properly in real time - could these apps read "charging" flag by another way?
Assume (just my assumption) - iOS may report "charging" in different ways, and some ways are not correct.
Since I am not an expert in iOS, I may only assume & guess.