This is just setting aliases for the hostnames kibana.local , logstash.local to point to the localhost itself so that you i.e. can access http://kibana.local:5601 in your browser, instead of http://localhost:5601 or http://127.0.0.1:5601 . This is neither necessary nor necessarily a best practice for all use cases.
Blog posts usually explain a very specific use case in an easy and consumable manner, but if you don't have the same goals or environments, you are much better off with reading our documentation than trying to half-follow a blog post where many things do not apply to you.
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.