Deadlocks are caused by poor database design, inappropriate isolation level, inefficient code etc.
Checkout my article (Tips for Minimizing Deadlocks) on SSWUG.org, in which I shared some tips that you can follow to minimize deadlocks in SQL Server online transaction processing (OLTP) and online analytical processing (OLAP) applications.