When you have IDE ports and drives on your mobo, EACH IDE port can handle TWO HDD units on its wide data cable ribbon. To identify them uniquely, the IDE system used a set of jumpers on the back edge of the HDD, between the wide data connector and the 4-pin power connector. There is no "standard" way for these jumpers to work, so use the diagram printed on the HDD (not a diagram from another HDD) to set your jumpers. In many cases, one of the settings will be NO jumpers applied.
To work at all, an IDE port MUST have a Master device (set by its jumper), and it should be on the Black connector on the END of the ribbon cable. (The Blue connector on the other end goes to the mobo port.) IF you connect a second drive to this same port you MUST set its jumpers to make it a Slave on the port, and plug it into the Grey middle connector.
Many mobos have TWO IDE ports on them. Just to identify them clearly, they are called the Primary and Secondary IDE ports. On the Secondary IDE port, setting jumpers for Master / Slave and plugging them into the ribbon cable follows the SAME rules as for the Primary port.
At one time, the boot drive HAD to be the Master device on the Primary IDE port. But on more recent mobos that is not so - you have a separate place in BIOS Setup to specify which of your several devices is the one you boot from. In fact, you set a priority sequence. Mine is set to try the floppy drive first (yes, I have one), then my optical drive, then my HDD. That way, if I have trouble, I can insert a bootable disk in either the floppy unit or the optical drive and it will boot from there.
Because of the old rule that the boot drive had to be the Primary Master, there is still a lot of confusion about Master and Slave units. With the more recent machines that link it totally gone. Now we should speak of the boot drive, and then all the other drives. (It is even possible to install two or more different OS's on HDD units and to have more than one boot drive, but that's more complicated than OP's machine.)
On newer machines there are SATA ports to connect SATA HDD units to. These ports each allow only ONE HDD on the port, so there is no such thing as Master and Slave for SATA devices. Those terms are only useful for IDE ports.