With every new product release, there is always the possibility of bugs and issues creeping in past the final release stage. In the case of the iPhone XS and iPhone XS Max, some units have been hit with charging issues as well as a bug where iPhones would rejoin the slower 2.4 GHz version of a WiFi hotspot rather than the quicker, more modern 5 GHz channel.
The iOS 12.0.1 update released by Apple recently is now making its way to devices via Software Update and fixes these issues and should be installed by owners of these new phones.