The batte of Khandaq is so called because

A.

it occured at a place known as khandaq

B.

The Jews of Yathrib collaborated with other to attack the Muslims

C.

the Muslims dug a ditch to defend madinah

D.

The prophet (SAW) decided to name it so

Correct answer is C

The battle of khandaq is so called because the Muslims dug a ditch to protect and defend the city.
The word khandaq (ÎäÏÞ) is the Arabised form of the Middle Persian word kandag (˜äϐ; meaning "that which has been dug"). Salman the Persian advised Muhammad to dig a trench around the city. The battle is also referred to as the Battle of Confederates.