Yes you can mix batteries.
It's not a good thing to do for allot of reasons. But most advice about not mixing batteries is don't do it when buying brand new batteries at big bucks! The same reasons still apply with old used ones, but for the cost who cares.
Things like use batteries of same age, same size, etc.. is great when buying those new ones to get the max life and least problems when spending the most money!
At $5 a battery who really cares? As long as it works good, and if eventually you kill a battery a bit early because it was the biggest one or the smallest one in a mismatch bank then what are you out of, $5 so who cares? Not worth worring over enough to run out and buy a matched set of 10 brand new ones for $1000 when you can have 20 good ones for $100.
Use some sense though when mismatching batteries. Try to keep them all about the same amphrs close as you can. Don't mix a 115amphr and a 17amphr and expect much.
Match the types also, don't mix normal deepcycle Lead Acid with gellcells or AGM.
Try to match the age and sizes and conditions, a 2 year old battery may last longer and work better if NOT mixed with a 10year old. But if the 2yr old has been abused and holds the same usable capacity as the well treated 10yr old then might as well mix.
As long as you try to match them up close as you can it does not really hurt anything to mismatch scrap batteries, they just may not last as long as if they were all matched perfectly. Charge and discharge may not be equal when mismatched, check a bit more often. Larger batteries may need water less often then smaller ones. Larger may not fully charge at times, occasionly check and top them off to a full charge.
Mismatching is not the best thing to do, but I figure it this way, I buy a $5 battery and use it long as I can then sell it for scrap at $5 and I am out of nothing and gained however much life it gave me. I do try to make them last a good long life, but I don't try to the point of doing without or buying a matched set of new ones!