There’s another project around where an Arduino nano or similar is used to count the pulses and the esp8266 is used only to send the data via AT, that would change your battery consumption drastically
Found it Autonomous impulse counter for water meters (attiny85 + esp-01)