See this article about updating payment methods on various platforms: 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."
Here is how you update your payment method on your iPhone or iPad:
1. Open the Settings app.
2. Tap your name.
3. Tap Payment & Shipping. You might be asked to sign in with your Apple ID.
4. Tap Add Payment Method, enter the new payment method, then tap Done.
5. Tap Edit.
6. Tap the red delete button next to the old payment method, then tap Delete.
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.