In particular, ocean trenches are a feature of convergent plate boundaries, where two or more tectonic plates meet. At many convergent plate boundaries, dense lithosphere melts or slides beneath less-dense lithosphere in a process called subduction, creating a trench.
Basically, more dense crust of the earth slides under less dense crust of the earth.