Likely, because it is a SATA drive. Refer to the Mac Mini teardown guide on this website for more:
Mac mini Late 2014 Teardown
Generally, you get two standards for hard drive connectivity, IDE, and the newer SATA. The Mac Mini 2014 has a SATA connector for hard drive.
You will have to install a proper OS on the new drive, whether Linux, Windows, or - duh - MacOS. I'd install that before trying the switch: at any rate, you will want to have a MacOS installation USB ready before attempting the switch.
Be aware that:
You're better off BACKING THINGS UP. There are no guarantees it will work flawlessly, no guarantees you wouldn't lose data, I make no expressed or implied guarantee myself about any of the advice I am giving here. These are just friendly recommendations and to be treated as such.
1) Apple has a kind of protection on installation (USB) media, something to do with dates (the date when you downloaded the file). In case you face an error when attempting to install the new OS, there is a procedure to force the installation manually, on command-line. Please get documented about that before attempting anything.
2) Changing the hard drive might void your warranty.
3) You might also encounter problems (to boot) if any part of the "firmware" has been trained to recognize your original hard drive, or due to some corruption of the NVRAM.
If you still wish to take the risk, I would suggest arming yourself with two bootable USBs. One for the MacOS installer, and a "rescue toolset" in the form of an Ubuntu LiveCD. If all else fails, the Ubuntu LiveCD will generally let you access partitions, help you access an EFI shell, etc.
And perform some recovery.
@dbahar - Don't be too quick to accept the first answer as you might mis something more helpful.