To clarify, are you looking for a way to block emails with a specific subject for a single account or single email account? If so, are the account or user level filter options in cPanel helpful?
The custom filter is not working properly, it also blocked emails with other subject.
I have created filter on this path: nano /etc/vfilters/domainname
Could you let us know the exact filter rule you created? Also, please use the "Account Level Filtering" option in cPanel to ensure all required files are populated correctly.