Nope, it does not hardcode every device. Rather it nowadays does exactly what Windows does and ask the device if it happens to be MTP.
If you're using a recent libmtp packaged by some sane person, the udev script (Fedora: /lib/udev/rules.d/69-libmtp.rules) will probe unknown devices using "mtp-probe". If the outcome is positive it is tagged as a music player and MTP device, then other udev scripts elevates that to be accessed by the desktop user. libmtp will autodetect the default Android stack and assign bug avoidance flags to cope with it.
The problems are not so much with libmtp really. Userspace has to hog devices after detecting an MTP compliant device and use libmtp or libgphoto2 to talk to it, here somewhere the problems start, since the desktop programs are not designed to share MTP resources in a good way.
The biggest problem is probably that absolutely noone is working on a common approach to supporting a wide variety of MTP devices on Linux, end-to-end. We basically need the pulseaudio rewrite of the user-facing and desktop integration parts.