To install old package versions, there is snapshot.d.o [1]. Basically, it has a copy of every state Debian repository was ever in. There is also a way to see every version of every package and to find the appropriate snapshot to install it from.
[1] https://snapshot.debian.org/