If we construct the quotient $\mathfrak{gl}(n,\mathbb C)/Z$ in the by-the-book way, the elements are cosets of $Z$ -- that is, each element is a set of matrices that differ from each other by adding or subtracting the same number to each diagonal element.
In search of a nicer representation of the quotient, let's see if we can appoint one of the matrices in each coset to be the canonical representative of the coset. Based on what characterizes each of the cosets, it seems that a natural choice for a representative would be the matrix where the sum of the diagonal elements is $0$ -- starting from a random matrix we can always achieve that by subtracting $\frac1n$ times the sum it already has from each diagonal element.
The sum of the diagonal elements is the trace of the matrix, so we're looking at the class of matrices with trace zero and wondering whether we can make a Lie algebra out of it.
If we paid attention in class, we will remember that the matrices with trace zero are exactly what make up $\mathfrak{sl}(n,\mathbb C)$ -- and it is now a simple task to check that $\mathfrak{sl}(n,\mathbb C)$ is indeed isomorphic to the quotient we're looking for.
The same holds for any field in place of $\mathbb C$, except when its characteristic divides $n$ (in which case $I$ has trace $0$, which ruins everything).
In the case $n=2$ we can also describe the quotient as $\mathfrak{sp}(n,\mathbb C)$, because $Sp(2,F)$ and $SL(2,F)$ are the same group for every field $F$.