How to use adb to push a hosts file in a non rooted device
You cannot do this without root access. The instructions given in that link are conceptually wrong to begin with. The fact that he was able to push a file into system partition implies that he had elevated privilege to remount system partition and write into it. Clearly, the instructions cannot fit under "Non root method" category. 

If you are into blocking ads through hosts file, you may try some answers here: In Android 6, how to deny an app permission to access the network?