You can use SQL Server Developer Edition for this, and there's no restriction against using it on a shared server, but you'd still have to pay for hosting the Windows server, which might be $5-$10/hour for an environment multiple users can work on.
A better idea might be to explore getting the students Azure educational accounts: https://azure.microsoft.com/en-us/free/students/