Not able to run aggregate query in ElasticSearch