I'm trying to to switch the price for a 'Sold' label on the product page of products that are out of stock.
If a product is sold out, the price should be hidden and in its stead should be a 'Sold' label.

I figured out that the price is placed in catalog\_product\_view.xml and it calls upon the `vendor/magento/module-catalog/view/base/templates/product/price/final_price.phtml` file, but I could not figure out where and how to bring in a condition to check whether product is sold out or not.

Can someone help here?
Thanks in advance.

Yuan