GoodNotes 5 is a universal app, which means you only need to buy it once to be able to get it on all your Apple devices.
For example, if you buy it from the App Store, you can redownload it to your Mac. The reverse is also true: you can buy it on the Mac App Store and redownload it to all your iPhones/iPads.