xroach (at least, this version, fixed for modern compilers) still works on current Linux distributions, as long as the desktop uses X and the root window is visible. Here it is running on Debian 10, with FVWM running the show:

(the cockroaches are in the top-left of the screen).
To reproduce this, regardless of your current desktop (assuming all four programs are available):
Xephyr :20 &
DISPLAY=:20 fvwm &
DISPLAY=:20 xterm &
DISPLAY=:20 xroach &
If you want real “old school”, there’s no need for FVWM and XTerm:
DISPLAY=:20 xsetroot -gray

Most “full-blown” desktop environments hide the root window, and there’s not necessarily an easy way to disable this. In any case as desktops move to Wayland, xroach-style programs will stop working, and their replacements will have to be desktop extensions rather than generic X or Wayland clients.