Probability that the commutator of two group elements is equal to a given element