Does the iPhone have a built-in volt meter or ammeter to monitor battery condition or is it just a age thing?...................
No, because Apple users aren’t smart enough to manage these things themselves, that’s why they are Apple users. As Archie Bunker used to say, “ipso fatso”!
The batteries themselves have built-in condition circuitry that can be polled and the iPhone is constantly checking that. It checks the number of full charge cycles, battery charge depth, amps, volts, temperature, etc. The battery itself does it to, and if certain criteria are met, the battery will shutdown all output due to overheating, overdraft, etc., to prevent damage to the device. That was what was happening in the unexpected shutdowns. Before power would flow from the battery again, it had to be placed back on a charger for the internal circuitry to be reset.
There are free and paid apps on the Apple App Store that allow users to see the condition of the battery and all those statistics. One I use is "Battery Life." It's free.