It seems (at least for me) that the condition $|K|>n$ —obtained by Vergilius— is useful only to show his characterization of the rank. We show that this result is valid for any field.
Proposition. Let $K$ be any field, $A\in M_n(K)$ and let $f:D\in M_n(K)\mapsto \DeclareMathOperator\degree{degree}\degree(\det(D+sA),s)$.
Then $\max_D f(D)=\DeclareMathOperator\rank{rank}\rank(A)$.
Proof. We may assume that $A=\DeclareMathOperator\diag{diag}\diag(N,U)$ where $N\in M_p(K)$ is nilpotent and in Jordan form and $U\in \operatorname{GL}_{n-p}(K)$.
i) $f(D)\leq \rank(A)$. Let $u=\rank(N)$; note that $\rank(A)=n-p+u$.
Consider one of the $n!$ elements of $f(D)$; with the $n-p$ last columns, we obtain at most $n-p$ times the factor $s$; with the $p$ first columns we obtain at most $u$ times $s$ (it's exactly the number of $s$ amongst the entries of $N$).
ii) There is $D$ s.t. $f(D)=\rank(A)$. We choose $D$ in the form $D=\diag(P,0)$. Then $f(D)=\det(P+sN)\det(sU)$. It remains to show that there is $P=[p_{i,j}]$ s.t. $\degree(P+sN)=u$.
Let $N=\diag(J_{i_1},\dotsc,J_{i_q})$ where $J_k$ is the nilpotent Jordan block of dimension $k$. Then it suffices to choose the $p_{i,j}$ equal to $1$ for the entries which are located at the bottom left of each block of Jordan and, otherwise, $0$.
Example: for $p=2+3$, $P+sN=\diag(\begin{pmatrix}0&s\\1&0\end{pmatrix},\begin{pmatrix}0&s&0\\0&0&s\\1&0&0\end{pmatrix})$.