Joint probability issue

So I’m looking at the for formula P(AB)=P(A|B)*P(B) and I’m wondering why this isn’t P(A)*P(B). Why do we need A given B to give us the joint probability of A and B?

P(AB) = P(A) × P(B) when A and B are independent.

When they’re not – when the probability of A changes once we know that B has occurred, and the probability of B changes when we know that A has occurred – then we need to use conditional probabilities.