@Alex Texera In macOS, run KeyChain and from the menu (should be under the first menu item, and then under Certificate Assistant) select command Request a Certificate from a Certificate Authority. Fill in the fields (enter a description and your email), then press the button to save the certificate signing request file on your computer. You might want to prepare more than one request, eg. for iOS development, iOS distribution, macOS development, macOS distribution, and so on.
Log in at https://developer.apple.com. A membership to Apple Developer Program would be needed to have your software on the App Store.
On that website:
section Certificates: upload the certificate signing request file (i.e. the file created with Keychain). Once a certificate is generated, you should download it and install it (double click) on your Mac. This step should be repeated for each certificate needed (e.g. iOS Development, iOS Distribution). Please upload a different certificate signing request file (i.e. a file generated with Keychain) each time.
section Identifiers: enter a an app identifier
section Devices: enter the UUIDs of your Apple devices
section Profiles: select the type of provisioning profile (e.g. iOS Development) and select (as defined in previous steps) app identifier, certificate, and devices. Download this file and install it (double click) on your Mac.
Hope this helps.