Filebeat is not creating index in ES?

Well after lots of efforts I was able to resolve the issue . It was to do with registry file, so I mentioned the path and things work perfectly.So this is what my new yml looks like.

filebeat.modules:
- module: apache2
  access:
   var.paths: ["E:/ELK/Module1/apache.log"]
output.elasticsearch:
  # Array of hosts to connect to.
  hosts: ["localhost:9200"]
filebeat.registry_file: E:/ELK/registry

Hope It will help someone.

Regards
VG