How many ships can be docked at Deep Space 9 at the same time?
Does the number of ships depend on their size?
It can presumably accommodate 6 large vessels at one time. Although I can't think of a time when we've seen all 6 being used. 6 + 3 + 9 + 6 = at least 24 ships (depending on size).
Three Galaxy class starships on the upper pylons might be pretty tight, but look they they could all fit.
The Defiant was often parked on one of the small or medium docking ports.
Additionally there are launch pads and internal docking bays for smaller vessels, such as the runabouts.
*Note: Pylon images taken from Memory-Alpha
Deep Space 9 had 6 docking pylons: 3 on the top and 3 on the bottom (referred to as "upper pylons" and "lower pylons").
Additionally, Deep Space 9 had 6 more internal docking bays:
So the answer is 6 large ships and at least 6 small ships. More than one small ship can fit into an internal docking bay, so the number really depends on how small the ships are.
These are pretty much the first results for googling "Deep Space 9 docks", so I'm surprised your research didn't tell you all of this already.