You have to install an operating system on the hard drive.
That Mac is old enough that the newest operating system it will run is OS X El Capitan.
Follow the instructions to do a recovery install located here:
How to reinstall macOS from macOS Recovery - Apple Support
When booted, you will likely need to use Disk Utility to create a new file system on which you can install El Capitan.