The vessels withdrew after receiving a warning from a Royal Navy ship, the Ministry of Defence says.