Magento 2.2.18 – Layout Update XML – not working at product level – need to add meta name=”googlebot” content=”NOINDEX,FOLLOW”

I need to be able to add some specific meta tags on a small subset of the products on my site.

I have tried adding:

<reference name="head"> <action method="setRobots"><value>NOINDEX,NOFOLLOW</value></action> 

using the Layout Update XML, but that does not get reflected when the page gets rendered.

What is the correct way in Magento EE 2.1.18 to add custom meta tags to specific products.

Note:the default layout in already has a meta robots tag, so I need the Update Layout Update XML to override the default.