This is is known issue among users, at this early stage.
No one knows if this is either a hardware or software issue, as of yet.
Also, no way to know if Apple has received enough feedback about this issue for them to be alerted to start working on a fix.
At this early stage, if you are still under the 14 day return policy, you could try returning the iPad Pro unit you have now and exchange it for another and test your Apple Pencil and replaced iPad Pro plugged into power in the store, to check if new units have this same issue or not, before you leave the store with another iPad Pro.
OR
Return it for now and get your money back.
OR
Keep the unit and hope enough feedback gets submitted to alert Apple that there is an issue with iPad Pro/Apple Pencil when the iPad is plugged into power.
Also, you might want to test Apple Pencil response without the matte screen protector, just to make sure this is not problematic of the screen protector.
Apple will never test for third party screen protection add-ons as Apple never recommends these for any iDevice.
AND/OR
Before you decide to return that iPad Pro, you can try and contact Apple here, directly, via the link below.
Contact - How to Contact Us - Apple
Talk calmly with Apple customer employees about your iPad Pro issues to them, first.
Also, I would post feedback directly to the feedback link below.
iPad Feedback
http://www.apple.com/feedback/ipad.html
The more feedback that gets posted about this new 2018 iPad Pro issue to Apple, the faster that cognizant Apple teams get alerted and start putting a fix into action for future iOS update release.
Cognizant Apple employees read ALL feedback generated from all of the various feedback pages and transfers the data to the proper and responsible Apple teams and personnel , but NO Apple employees will ever respond with any type of direct, individual replies from the feedback you post.
Good Luck to You!