A G5 is a great machine to run 10.5.8 on:
Lots of old good PowerPC and Universal applications work with a G5. Just don't get an Intel Mac only application, as it won't work with it.
when I plug it it there is a red light in the front and web you press power it beeps,
How many beeps?
Is RAM installed?
You need a hard drive with OS X installed to use the machine.
The minimum OS required/supported is determined by production date/series.
Open the side panel and locate the small tag (lower center) with the serial number.
Enter the serial number in the following sites' database to find out exactly what series of machine yours is: