First you need a firmware file. You can build one yourself with the Toolchain or download one:
To flash the ESP8266, you'll need first need to wire things up. See Getting Started with ESP8266 for the basics.
Connect GPIO 0 to ground and reboot the ESP8266 to enter flashing mode.
The NodeMCU flasher is designed for use with the NodeMCU firmware, but it can also be used to flash other firmware files. Windows-only currently, but a cross-platform version is in the works.