Yes, and the change is small: instead of voting on labels, k-nearest neighbours (KNN) averages the target values of the k nearest neighbours. Predicting a house price means taking the mean price of the k most similar houses.
A common refinement weights each neighbour by the inverse of its distance. Closer points then pull the prediction harder, which smooths out the jumps you see when k is large.
Two costs are worth knowing. The prediction surface is a staircase rather than a smooth curve, because a whole region shares the same neighbour set. And the model cannot extrapolate at all. Feed it an input beyond the training range and it returns the average of the same edge neighbours, flat forever. That makes it a poor fit for trending data such as prices over time.
Rewriting in plainer words…
This answer doesn't lend itself to a diagram - it reads best . No credits were charged.