It's neither a Gmail problem nor a Thunderbird problem.
Gmail has some of the best spam filtering in the business, and it's doing with spam exactly what it should do - classifying it as such and moving those messages to the spam folder.
Gmail itself will, as Gene has noted, purge off anything in the spam folder that's older than 30 days each and every day, and that will be purged out of your spam folder under Thunderbird as well provided you're using IMAP access to your account, which has been the Gmail default access method for years now.
Neither Gmail nor Thunderbird have any ability to prevent you from getting spam nor to control the volume of spam you receive. What they can do is filter/classify it appropriately and move it to a folder where it will not be a nuisance in daily life.
It is a good idea to check one's spam folder daily for any possible "not spam" messages that may have been classified as such incorrectly. But I have not had Gmail do this to me for many years, and that's on multiple accounts.
Brian - Windows 10 Pro, 64-Bit, Version 2004, Build 19041
Always remember that computers are just glorified light bulbs - they rarely fail in continuous use and usually go pop when turned off and on.
~ Technician with the username Computer Bloke, on Technibble.com