extends KinematicBody2D

func win():
	if coins == 2:
		Player.global_position = Vector2(0, 0)

    What about it doesn't work? What do you expect to happen and how are you calling this win() method?

    GameTab Hi! Please consider adding more info.
    Looking at your code, I can see that no variable coins is defined - try this:

    extends KinematicBody2D
    
    var coins = 0
    
    func win():
    	if coins == 2:
    		Player.global_position = Vector2(0, 0)

    I am not sure if this is the problem, but it should fix code errors you have!