Usually you can push a hernia back in, that might depend on where it is, I am not sure. Is it located in your groin? If so and you can push it back into the stomach cavity it is likely to be a hernia. Also, doctors usually do the caugh test, if you caugh or strain your stomach muscles the bulge usually pushes out and that is how they can diagnose it. Did your doctor do this?
If you are in doubt you can always go to another doctor and double checkt, maybe don't tell him you have been to someone else already and what their diagnosis was.
If the lump is in your groin it might be a lymph node if it feels hard, that is the only other alternative I can think of.
I hope it get's better soon and that you don't have a hernia. Either way, you should really consult another physician just to be sure if what I have written above leaves you in any more doubt.
I hope this helps,
take care.