Active sonar. It doesn't matter if the sub makes noise or not, it is still a huge chunk of metal and can be located with an active sonar. It's a bit like an underwater radar, only that it uses sound pulses instad of electromagnetic waves.
An illustration on how it works