Valuing a currency forward

I’m just trying to understand the formula better, but how come the Spot is discounted by the foreign Rf and the Forward is discounted by the domestic Rf?