Let $O_K$ be a complete DVR with finite residue field $O_K/(\pi_K)=\Bbb{F}_q$, let $L/K$ a finite extension, $O_L/(\pi_L) = \Bbb{F}_{q^f}$. The valuation extends uniquely to $O_L$, by Hensel lemma $\zeta_{q^f-1} \in O_L$. The ramification index is $e= v(\pi_K)/v(\pi_L)$.
$O_L$ is complete, its completion being $$\overline{O_L}=\{ \sum_{n\ge 0} c_n \pi_L^n, c_n\in \{\zeta_{q^f-1}^j\}\cup 0\}= \sum_{m=0}^{e-1}\pi_L^m \sum_j \zeta_{q^f-1}^j O_K\subset O_L$$
Thus $$O_L= O_K[\zeta_{q^f-1},\pi_L]$$
Let $$\alpha = \zeta_{q^f-1} (1+\pi_L)$$ Being a finitely generated $O_K$-module $O_K[\alpha]$ is complete too, and since $v( \alpha^{q^f-1}-1) =v(\pi_L)$ we get that $$O_L = \{ \sum_{n\ge 0} c_n ( \alpha^{q^f-1}-1)^n, c_n\in \{\alpha^j\}\cup 0\}=\sum_{m=0}^{e-1} ( \alpha^{q^f-1}-1)^m\sum_j \alpha^j O_K= O_K[\alpha]$$
I’m not sure what the problem is. You have $K\subset L$, and between them you have the maximal unramified extension of $K$ in $L$, call it $K^{\text u}$. You know that the residue field extensions $f^L_K=f^{K^{\text u}}_K=[\kappa_L:\kappa_K]$, while for the ramification degrees, $e^L_K=e^L_{K^{\text u}}$, i.e. the top layer is totally ramified, the bottom is totally unramified. You have to use multiplicativity of both the residue field degrees $f^?_?$ and the ramification indices $e^?_?$.
If this isn’t enough for you, get back to me in a comment, and I’ll try to fill in any missing details.
EDIT — Addendum:
You have asked why, when adjoining a primitive $q^f$-th root of unity to $K$ you get the maximal unramified extension of $K$ in $L$. Let’s see how this works:
I’ll change your notation slightly, letting the residue-class fields be $\kappa$ and $\lambda$, so that my $\kappa$ is your $\kappa_K$, and my $\lambda$ is your $\kappa_L$. Now, by definition, the residue-field extension degree of $L$ over $K$, which we’re denoting $f$, is $[\lambda:\kappa]$. Let $\zeta_0$ be a primitive ($q^f-1$)-th root of unity
in $\lambda$, say with minimal $\kappa$-polynomial $\varphi(X)\in\kappa[X]$. I’m going to call $q^f=Q$, for convenience.
Now lift $\varphi$ to any monic polynomial $\Phi(X)\in K[X]$; this is still $K$-irreducible. Since $\varphi$ splits into linear factors over $\lambda$, one of these being $X-\zeta_0$,
Hensel tells us that $\Phi(X)$ also splits into linear factors over $L$, one of these being $X-\xi$ with $\xi\mapsto\zeta_0\in\lambda$, but of course $\xi$ need not be a root of unity at all.
Nonetheless, $\xi^{q^f}\equiv\xi\mod{\mathfrak M}$, where $\mathfrak M$ is the maximal ideal in the integers of $L$. I’ll ask you to consider the sequence
$$\xi, \xi^Q, (\xi^Q)^Q=\xi^{Q^2},\xi^{Q^3},\cdots$$
which you easily show is $\mathfrak M$-adically convergent, all of the terms being congruent to $\xi$ modulo $\mathfrak M$. And of course the limit is a ($Q-1$)-th root of unity reducing to $\zeta_0$ in $\lambda$.
This limit is what I’ll call $\zeta$; it’s a primitive such root. Its
minimal polynomial is congruent to $\Phi$ modulo $\mathfrak M$, that is, it reduces to $\varphi(X)$, and it’s still irreducible.
Putting it all together, what do we have? $K(\zeta)=K(\xi)$ is of degree $f$ over $K$, unramified since its residue-field degree is equal to its vector-space degree. And certainly there is no larger unramified extension
of $K$ in $L$. So I think that you have your maximal unramified extension, generated by a root of unity of the right type.
Best Answer
As you stated it is not true, try with $K=Q_3,L=Q_3(i), f= x^2+3^2$ then $f\equiv x^2 \bmod 3$ but the residue field is $F_3(i)=F_9$.
Let $O_K$ a complete DVR with finite residue field and unique maximal ideal $(\pi_K)$ and $L/K$ a finite extension.
$v(b) = \frac1{[L:K]}v(N_{L/K}(b))$ extends the valuation to $L$, let $O_L=\{ b\in L,v(b)\ge 0\}$
Claim : $O_L$ is monogenic $O_L=O_K[a]=O_K[x]/(f)$
$f = \prod_j f_j^{e_j}\bmod (\pi_K)$
each $(\pi_K,f_j)$ is a maximal ideal of $O_L$
let $\pi_L$ an element of minimal positive valuation in $O_L$
$(\pi_L)$ is the unique maximal of $O_L$ which means $(\pi_K,f_j)=(\pi_L)=(\pi_K,f_1)$ ie. $f_1\equiv f_j\bmod \pi_K$ ie. $f = f_1^e\bmod (\pi_K)$
and $O_L$'s residue field is $$O_L/(\pi_L)=O_L/(\pi_K,f_1) = O_K[x]/(f)/(\pi_K,f_1) =O_K/(\pi_K)[x]/(f_1)$$