Proving that there doesn't exist a binary code with parameters [6,5,4] I'm new to code theory and I'm having trouble with proving if a code doesn't exist in general.
I found a binary code with the parameters [6,4,4] but I don't really understand why there cant be one with parameters [6,5,4].
It would help a lot having an example of such problems.

Thanks in advance.
Assuming you mean a linear error-correcting code, a common interpretation of "[6,5,4] code" is a code using $6$-bit codewords to represent $5$-bit messages where any two distinct codewords differ in at least $4$ bits.

There are $2^6 = 64$ possible codewords.  We have $2^5 = 32$ messages.  In the lattice $\{0,1\}^6$, each codeword is surrounded by an open ball of radius $4$ containing no other codewords.  One can use the Singleton bound to show that $5 + 4 \leq 6 + 1$ if this code is realizable.  However, $9 \not \leq 7$, so this code is not realizable.

The Singleton bound is a very loose bound.  Generally, for a realizable [c,m,d] linear error-correcting code, the inequality is $m+d \leq c+1$.  The Singleton bound also indicates there is no realizable [6,4,4] linear error-correcting code.

There is another way to show there is no [6,5,4] linear error-correcting code.  We have $64$ codewords and $32$ messages.  By distance 4, there can be no pair of messages assigned to complementary codewords.  By the pigeonhole principle, since there are only $32$ such pairs of codewords, any such pair has exactly one message assigned to it.  This means there is a message assigned to exactly one of $000000_2$ and $111111_2$.  Similarly, there is exactly one message assigned to the codeword pair $000111_2$ and $111000_2$.  However, no such assignment is possible since any member of one pair is only distance three from either member of the other pair.  \begin{align*}
d(000000_2, 111000_2) &amp;= 3 \text{,} \\
d(000000_2, 000111_2) &amp;= 3 \text{,} \\
d(111111_2, 111000_2) &amp;= 3 \text{, and} \\
d(111111_2, 000111_2) &amp;= 3 \text{.}
\end{align*}
Consequently, there is no [6,5,4] linear error-correcting code.

(This counting argument can be adapted to show there is in [6,4,4] linear error-correcting code.  Take the codewords in groups of $4$ having matching first four bits.  This gives 16 groups each member of which differs from the other members of its group in only two bits, so at most one of those codewords is assigned to a message.  There are 16 messages, so each group is assigned exactly one messsage.  Then the groups $0000{*}{*}_2$ and $0001{*}{*}_2$, where "$*$" represents a bit whose value is either $0$ or $1$ (but this is not critical since either choice gives a codeword in the same group), each have a message, but regardless of which codeword is chosen in each group, those codewords differ in at most three bits.)
Assuming you are talking about non-trivial perfect binary codes of the form $[l,x,d]$, we have that the code can correct up to $e=\lfloor\frac{d-1}{2}\rfloor$ errors. If a non-trivial perfect binary code exists, it must hold that $\sum_{i=0}^e\binom{l}{i}$ is a power of $2$.

In our case, $d=4$, so $e=\lfloor\frac{3}{2}\rfloor=1$ and $l=6$. $\binom{6}{0}+\binom{6}{1}=1+6=7$ which is not a power of $2$, so such code cannot exist, unless it's trivial.