MacOS does use dlls or sos. It gives the appearance that they don't exist because the application you are clicking on is actually a directory with an extension of .app. Everything the application depends on is in the directory so when you drag it around places, everything goes with it. As for shared dlls, they are stored in the library directory. The application contains a manifest that tells it which libraries it relies on. Its all very simple.
so in theory MacOS can still suffer from dll hell unless the library directory stores multiple versions of the Library.
Linux systems (I believe it's also in most *nix systems) store the dynamic link libraries in /lib and /usr/lib. with .so(dynamic-linked) or .a(static-linked) in extension.
And they put the version number at the end of the file. Then provide symbolic link to the filename without version in extension as the current version.
So you'll see:
libsomething.so -> libsomething.so.4.3.3
libsomething.so.3 -> libsomething.so.3.1.0
libsomething.so.4 -> libsomething.so.4.3.3
In some system that doesn't use package management systems.
Note that on most systems, some of these libraries are left behind intensionally for backward compatibility reasons. (e.g.: the *-compat packages)
If you install an application that requires previous version of glibc runtime, just install the current version of glibc-compat and you'll get all the previous versions of glibc-runtime. That's how they solve the DLL hell problem.