Hi @Alberto-6036,
Welcome to the Microsoft Q&A platform!
According to your issue, I have the following to share with you.
These actions are used with different Policies and Transport Rules. If the button is grayed out, which means the action is not supported with this quarantined messages.
For ‘Deny’ and ‘Block sender’ action you mentioned above, you could check the screenshot below to find out what is required.
You can refer to ‘Take action on quarantined email’ part of Manage quarantined messages and files as an admin - Microsoft Defender for Office 365 | Microsoft Learn for more information.
If the answer is helpful, please click "Accept Answer" and kindly upvote it.