Horizontal space in Garaj Mahal (my garage shop) is VERY limited and precious. Long ago I hit upon a temporary solution that worked well enough that now it is a permanent accessory.
I bolted a piece of 2 x 4 to the front edge of the work bench a previous owner of the house had graciously installed. Two vertical holes were bored into it to provide a slip fit to two truncated 3/8" bolts.
The accessory table consists of a piece of 3/4" plywood to which has been hinged a box frame "leg" made of 2 x 2s. I always intended to put some diagonal braces on the leg but it works well without same and I never got around to doing it. As the picture below shows, this assembly folds flat enough to fit into most slots between machines or tool cabinets...
This picture shows the "leg" partially extended...
In use, the accessory table is put onto the 2 x 4 "ledge" attached to the work bench and adjusted to line up the holes in the top with those in the ledge. The bolts are dropped through the holes to lock the table in place and prevent it from sliding off the ledge, which could be both dangerous or disastrous. Again, I could have added a lock to the leg to prevent it folding when extended but it never seemed to be a problem so I didn't. If you construct something similar, think about your personal situation and add appropriate safety features.
The table works very well. It has several features that are important to me...
As shown, the bench motor projects out over the table (this wasn't accidental). I can clamp sanding/grinding jigs to the table and use the motor directly.
I can walk around three sides of the table which makes getting the most comfortable body placement for the job at hand easy.
I can clamp work to be sawn so as to project over the edge of the table.
For sit-down work I can sit on a stool and get my legs under the table, something I can't do at the workbench proper.
By far though, the most important feature is that I CANNOT get my car into the garage (yes, Garaj still houses two full size cars every day) with the table in place. That means that the table MUST be cleared and stored when the workday is over. No sedimentary build-up of tools and half-finished projects can occur because of this mandatory daily tsunami.