A passenger caused major disruption at York Railway Station because his mobile phone battery had run out of power, the city’s magistrates heard.