6. As shown in Figure 2, given that $C$ is a point on the semicircle $\odot O$ with diameter $A B$, $I$ is the incenter of $\triangle A B C$, the extensions of $A I$ and $B I$ intersect the semicircle $\odot O$ at points $D$ and $E$ respectively, and $A B=6$. Then the length of $D E$ is ( ).
(A)3
(B) $3 \sqrt{2}$
(C) $3 \sqrt{3}$
(D) 5
6. B.

It is known that $\angle C=\angle A E B=90^{\circ}$,
$$
\begin{array}{l}
\angle A I E=\angle I A B+\angle A B I \\
=\frac{1}{2}(\angle C A B+\angle A B C)=45^{\circ} .
\end{array}
$$

Therefore, $\angle E A D=45^{\circ}$.
In $\triangle A D E$, by the Law of Sines we get
$$
D E=A B \sin \angle E A D=6 \sin 45^{\circ}=3 \sqrt{2} \text {. }
$$