To setup a filter in Thunderbird, go to Tools, and click "Message Filters". The "Message Filters" window will pop up. Click New, and the Filter Rules dialog will open.
In Thunderbird, click on TOOLS>MESSAGE FILTERS>NEW. Make sure you type a descriptive Filter Name that you'll remember in six month - "Filter 1" is not ideal, for example.
The rules follow simple IF-THEN logic. If the SUBJECT - CONTAINS - XX
then MOVE to XX
Select move, delete, mark as read, etc as you desire. At any time, if a rule is no longer needed, simply highlight the rule and delete it.
We recommend you do not use DELETE as an option at first. Sending to the trash or junk folders is a better option, as this allows you to review your results. After sure all is working as desired, edit the rule to delete if that is your wish.