Legacy Alerts Template Labels

Hi

As mentioned here Grafana legacy alerts templating we can use labels in the notification message.
In the documentation is Prometheus used as an example and I guess the Labels are coming from Prometheus which are used there.

For example
Here we can see that instance is set.

and in the message is then ${instance} used as a variable to set the value if it is in the message.

Question
Is there a way to accomplish the same with the Elasticsearch data source?

Use Case
I have a query that returns me the deployments and their “health” from my Kubernetes cluster. The metrics are gathered with Metricbeat and then sent to my Elasticsearch cluster.
This query returns me the percentage of pods which is online in relation to the needed pods for a deployment:

Now in the Alert tab, I wanna create an Alert and add the deployment name to the message.