V
Vale
Guest
In the case of TOS, this term might mean nacelles or the secondary hull, rather than discreet tanks within the ship, like those in TNG.
Scotty specifically refer to "magnetic bottles" and "the magnetic field that bottles up the antimatter". Scotty enters what is variously referred to as an access tube or a service crawlway leading to the matter-antimatter reaction chamber. There are other engineering staff just outside the crawlway and Scotty refers to "explosive separator charges to blast me clear of the ship", rather than "us", so it's unlikely to be the entire secondary hull with other people just hanging around the corridors waiting to see if they'll die or not.
My assumption is that this was based on the Jeffries-era "nacelles are completely integrated engine units with their own matter, antimatter, and reactors" paradigm of how warp drive worked, and that Scotty was indeed inside one of the warp nacelles at this point. However, ejecting an entire warp nacelle when you're travelling way above your maximum rated speed and the ship's already in danger of structural collapse is probably not a great idea; it being a single antimatter storage pod being ejected makes more sense, and is more likely to leave the rest of the ship intact.