See this article about updating payment methods on various platforms (iPhone, Mac, etc.): If you need to change or update your Apple ID payment method - Apple Support
"If you change your address, the credit or debit card information that you use with your Apple ID might be automatically updated by your financial institution, and you don't need to take action. But if there's an issue [such as you having a subscription or being a Family Sharing Organizer], add a new card first, then remove the old card."
Update your payment method on a Mac
1. Open the App Store.
2. Click your name or the Sign In button.
3. Click Account Settings.
4. Next to Payment Information, click Manage Payments. (If you're using an older version of macOS, click Edit next to Payment Type.)
5. Click Add Payment, then enter the new payment method. Click Done.