The probability you are looking for is defined as the number of cases where the three friends are into the same group, divided by the total number of ways the three friends can be put into the groups, that is:
$$Probability = \frac{\text{number of ways to the three friends can be together}}{\text{number of ways the three friends can be put into the groups}}$$
Let's first find the number of ways to the three friends can be together. Either they can all be in the first group, all in the second group, all in the third group, or all in the fourth group. Thus, there are 4 ways the three friends can be together.
Let's then find the number of ways the three friends can be put into the groups. The first friend could be put into any of the four groups, so we have 4 possibilities for the first friend. The second friend could also be put into any of the four groups, and the same is true for the third friend. Thus, there are 4 cases for the first friend, and for each of these cases there are four more ways with the second friend, and for each of these cases there are four more ways with the third friend. The total number of ways the three friends can be put into the groups is thus $4\times 4\times 4$.
To better understand the preceding paragraph, I suggest you make a tree of possibilities of the different ways you can put the three friends into 4 groups.
ADDED
I think it is rather strange to calculate the probability assuming the number of students is $4n$. We should suppose that the number of students is any positive $n$.
One way to look at the problem is to have each of the $n$ students assigned a number between 0 and 3, each number corresponding to a particular group. We can imagine the students placed randomly in a line, and then having somebody giving everybody a number in the sequence $0,1,2,3,0,1, ... $. The number at which ends this sequence depends on the number of students, but the groups are approximatly of equal sizes.
The total number of ways the three friends can be assigned a number is simply $\frac{n!}{(n-3)!}$.
The number of ways the three friends can be together depends on the number n.
If $n$ is divisible by 4, there is $n\times\frac{n-4}{4}\times \frac{n-8}{4}$ ways the three friends can be together.
More generally, expressing $n$ in the form $ n = 4k + x$, where k and x are natural numbers and $0\leq x \leq 3$, we have
$$ x \frac{(k+1)!}{(k-2)!} + (4-x)\frac{k!}{(k-3)!} $$
ways the three friends can be together.
Therefore, the probability that the three friends will be in the same group is
$$\mathbb{P}(\text{same group}) = \left( x \frac{(k+1)!}{(k-2)!} + (4-x)\frac{k!}{(k-3)!}\right) \times\frac{(4k+x-3)!}{(4k+x)!}$$
Note: I checked my result with mathematica to make sure I didn't make any mistake. I get about 1/16 when n is large.