If you have a Commodore A1200 it will be electronically compatible.
However most A4000 drives are 1,5" high, thus the case will not fit together properly.
If you find a 1" high Amiga HD drive, you can get the case on, but the eject button will not fit properly and you must do something about that.