This is a common problem with Shopify, you will need to enable the product to be back-ordered within the product settings and you'll need a service to come back and fulfill these items once they are in stock. You might want to check SKUSavvy. It will automatically pause the order once a product is marked as back-ordered, it will then split the shipment so that if other items in the order can be shipped, you can ship these first. Once your product is back in stock, you can unmark the product as back-ordered (or simply check in more inventory) and it will re-open the orders for fulfillment, then alert customers as usual about the product shipment.
A split order with one product backordered