With the release of macOS 11 (Big Sur), Apple introduced a new design language that added more padding throughout the interface. This is what a Finder window looks like on macOS 12 (Monterey) (see the sidebar and the table view):

If you want to restore the old, more compact style used on macOS 10.15 (Catalina) and below, there are two Terminal commands for that. Simply run:
defaults write -g NSSidebarUsesGoldenMetrics -bool FALSE #force a plain style on sidebars globally
defaults write -g NSTableViewCanUseGoldenStyles -bool FALSE #force a plain style on table views globally
And you will get your UI looking like this:

If you wish to enable it only for a certain app, provide the app’s bundle identifier instead of -g. For example, if you wish for the change to apply only in Finder, run:
defaults write com.apple.finder NSSidebarUsesGoldenMetrics -bool FALSE #force a plain style on sidebars in Finder
defaults write com.apple.finder NSTableViewCanUseGoldenStyles -bool FALSE #force a plain style on table views in Finder
To revert back to the default style, just delete the setting:
defaults delete -g NSSidebarUsesGoldenMetrics #delete the sidebar setting globally
defaults delete -g NSTableViewCanUseGoldenStyles #delete the table view setting globally
defaults delete com.apple.finder NSSidebarUsesGoldenMetrics #delete the sidebar setting in Finder
defaults delete com.apple.finder NSTableViewCanUseGoldenStyles #delete the table view setting in Finder
