There is more than one ann.
In simple terms, the ann of position or place can be replaced with ansin - so your "was there cancer there" would be an raibh ailse ansin?. The ann of existence is sometimes translated as "in it" (the prepositional pronouns for i are ionam, ionat, ann, inti, ionainn, ionaibh and iontu), so lá breá a bhí ann means "it was a great day", but some might translate it more literally as "a great day was in it" or "there was a great day in it".
In this case ("An í ailse a bhí ann?) it's the ann of existence - "is it cancer that was in it?" or "is it cancer that it was?"
(ann/ansin isn't quite that simple, but making that connection can help to make this explanation clearer).