As far as I know, there is no internal functionality to do that.
However, you can achieve this by simply adding a prefix of get_tree() to each print statement, as each window instance operates independently and has its own scene tree. You can also create a utility function as follows:
# I always like to give type notation
func print_local(node: Node, message: String) -> void:
print(node.get_tree() + ": " + message)
When you print the scene tree returned by get_tree(), it will converted to a string like SceneTree#7304. Directly printing the scene tree is possible but may not be as pretty; you can explore other ways to convert the scene tree into a more readable text.