Density yes, but more importantly 1) speed vs traveling by car, 2) starting and stopping in places people want to travel between, 3) safety, 4) real estate prices/regulation.
Density goes to number 1 (more traffic = better reason to use the subway) and 2 (more likely to be able to serve people’s desired trip)