Given it's location it may have just been irritated. Did you scratch it or rub it against anything by accident that may have caused it to become sore? I have done this before with moles, and they usually resolve themselves in a day or two.
The back of your knee is not a common location for melanoma (usually it's seen on your back or areas more prominently exposed to the sun).
Without seeing it and knowing how much it has changed, there's not much more I can offer, but it may be safe to have a dermatologist look at it!