How does a deadlock occur in Java?
A deadlock occurs when a thread calls the `sleep()` method and prevents the other threads from acquiring a lock.
Thatâ€™s incorrect. Deadlocks happen when threads are blocked waiting for resources, not due to calling `sleep()`.
Can you explain how the use of multiple locks can lead to a deadlock situation?