Matchmaking is random. ..too many competing priorities to give consistently good results.
If you use the server browser to search for and join a persistent community server, you will get a server with a fixed map rotation that won't randomly decide if you should be attacker or defender over and over or whether you should play the same map over and over. The bonus is that your party will never again break at the end of a match, and you won't need to re-matchmake every round, and you won't suddenly play with a whole new random group of people each round, and what was a match with few bots is unlikely to be full of bots next round.
Just use the server browser, apply the filter which specifies which game mode you want to play (in order to remove all the farms and crap you aren't interested in from the results), and join the server with a description that matches what you want. You can also tell it to not show you empty servers and only show you full or near-full servers.