Even if you're out of stock you can allow
your customers to order a product. It will also display a custom
message you set yourself.
The option is located on the product edit page, in Inventory ->
Products. Simply select the product and scroll down to the "Display
Settings" section. The last option there is "Advanced Orders", put a
mark in the checkbox and input the message you want to display in the
textbox next to it, then save the product. Once the stock value of that
product reaches 0 the message will display on the product details page.