Use %if in schema.yml

I have requirement where the DB Name in Schema.yml has to be derived.

database: ‘{{"_PRODUCT"}}’

But if need to add a if condition and set the value of database, as below

{% if == ‘LOCAL_DEV’ %}
database: DEV_PRODUCT
{% else %}
database: ‘{{"_PRODUCT"}}’
{% endif %}

with the above coded added to schema.yml I see following error :

Raw Error:
while scanning for the next token
found character '%' that cannot start any token
  in "<unicode string>", line 7, column 6: