Just like with all kinds of user permissions on UWP apps, capabilities must be explicitly set through the manifest file.  This goes true for using any serial ports too.

Normally, the manifest in a UWP project has a list of checkboxes with various capabilities that can be turned on and off graphically.  Unfortunately, “Serial” is not one of them.  Instead, you must go into the raw code for the manifest (instead of the GUI) and paste this:

  <DeviceCapability Name="serialcommunication">
    <Device Id="any">
      <Function Type="name:serialPort" />