Counting pulses and using them

if you want simply to toggle with each press of the button, place

digitalWrite(ledPin,!(digitalRead(ledPin)));

into your code as you detect a button push or a change of buttonState.

Your sketch however, seems only to increment the button counter when the state changes from low to high. Id that what you intended?