This is usually the sign of an unfertilized female flower. Cucumber plants have male and female flowers. Bees go around spreading pollen from the male flowers to the female flowers. All female flowers have a bump behind the flower. This becomes the cucumer fruit. When the flower falls off, fertilized or not, the female bump starts growing as if it truly had been fertilized. If it wasn't fertilized it will grow about an inche long, start to turn yellow and brown and die.
Sometimes cucumber plants have more male than female flowers, in fact, male flowers usually open first. Unless you have both male and female you won't get cucumbers.
Try to see if you can tell the difference in the flowers. Remember, the females have a round bump behind the flower's base. The males don't. If you have both, but are not fortunate to have bees around you can use a little craft paint brush ado the polination yourself. Brush the pollen on the male plant and transfer it to the female plant. You should see that the bumps become full grown cucumbers after doing this. Zucchinni and other squash work the same way.