The payment method should be issued in the same country as what is set for the Apple ID account. (If you have e.g. a Canadian Apple ID account, then you must also use a Canadian card.) That has to match.
The payment method for subscription services should support automatic and periodical billing.
Some debit cards in some countries can only be used for adding balance to your account.
Some cards may have set restrictions for international billing, which may be a requirement in some countries. Ask the card issuer/financial institution/bank about that, if applicable. (E.g. Apple transactions in Western Europe go through Apple Ireland.)
What is your card type? What is your country or country-like region?
Payment methods that you can use with your Apple ID (by country) - Apple Support
It works by linking a pre-authorized payment method to your Apple ID account, so that you can pay subscription fees automatically and other purchases with a few clicks.
If you believe to do it all correctly, and it still doesn’t work, then contact Apple Support for assistance.