you certainly can, with a few "buts".
you will want to make sure that the fish going in to QT go in at the same time. anything you add to QT resets the clock.
you will want to make sure that the fish tolerate medications equally well. e.g. you wouldn't want to quarantine something that doesn't tolerate copper medications, like a dragonet, with something that you plan on treating with copper (either prophylactically or not).
you will want to make sure that there is ample room for the fish to hide. i like sections of PVC, especially elbows and t fittings. they're inert, they don't really absorb much, and they are easily to sterilize or replace if need be.
if you're using an established QT tank, make sure you're paying close attention to your levels of ammonia and such, and acting accordingly. more fish, more food, more waste, more ammonia.