Spotting

Ok so I started spotting in between periods but I was just at the hospital and the said I wasn’t pregnant? What else could it possibly be?