Tell me please if the following sentence is correct.
John asked me if I had something to eat and I told him that there were eggs.
Is it necessary to specify where those eggs are? For example:
There are eggs in the kitchen.
I wouldn't say your sentence is incorrect, and no, you don't need to specify the location of the eggs.
That said, some might agree that this version reads a little less awkwardly than your original:
John asked me if I had something to eat and I told him that we had eggs.