As you may already know, the Community of Madrid offers a childcare grant (models 140 and 233).
The answer is yes, you can pay the corresponding amount, applying full tax exemption to the final sum.
What the grant does is reduce the monthly cost you have to pay for the nursery. With that said, the amount you ultimately have to pay has no limit for tax exemption.