My hunch is so it can identify your app among other apps on Mac OS. This is likely for updating and/or to allow the end user to have an idea of who made the app. At least, that's how I understand it from when I was doing iOS development.
I did some research, and it looks like its used in information.plist, which is stored with the signed application. Here's a link to a page from Apple on code signing.
As far as UWP, it looks like a certificate file is generated when you submit to Microsoft. There's also some other stuff here that may provide some insight into signing UWP programs.
As far as the Mac OS exports go, I would say yes, you are supposed to put something unique.