The software will run on the old server just fine. You will need to purchase a new license to install SQL Server 2005. However Microsoft doesn’t sell SQL Server 2005 any more. You will need to purchase a SQL Server 2008 R2 license and use the downgrade rights to install SQL Server 2005.
You’ll have to supply your own install media so hopefully you have some. Microsoft may be able to provide you with some for a small fee.
However you should really look at upgrading to a newer version of SQL Server as SQL Server 2005 will be out of support next year.