As one can see from the table, the only remainders upon division by 11 that the fifth power of an arbitrary integer $n$ can give are 0, 1, and 10. On the other hand, integers of the form $f(n)$ give only remainders 1, 3, 4, 5, 6, 7, and 9 upon division by 11, whereby the remainder is 1 only if $n$ is divisible by 11. Consequently, $f(p)$ can be the fifth power of an integer only if $p$ is divisible by 11. As $p$ is prime, the only possibility is $p=11$. And indeed, $f(11)=2\cdot 11^3+4\cdot 11^2-3\cdot 11+12=3125=5^5$.