Set up your grill for direct and indirect cooking over medium heat and preheat it to 400°F (200°C).
In a small bowl, stir together the butter, garlic, chopped rosemary leaves, and soy sauce, then season with pepper. Set aside at room temperature.
Wipe the mushrooms with damp paper towels to clean, if necessary, and trim the ends of the stalks. Place the mushrooms on a rimmed baking sheet, drizzle with a little oil, season with salt and pepper, and toss to coat.
Turn the mushroom caps gill-side up on the baking sheet. Using a spoon, draw a line in the butter divvying it in half. Spoon half the butter on the mushrooms, dividing it evenly among them.
If desired, dampen the rosemary stalks with a little water and throw them directly on the charcoal or place them across the grate of your gas grill over direct heat. Place the mushrooms, gill-side up, on the grill over direct heat and close the lid. Grill the mushrooms until softened and the tip of a sharp knife can easily be inserted into the thickest part, 5 to 7 minutes.
Move the cooked mushrooms to the perimeter of the indirect heat zone. Divide the remaining butter evenly among them and wait for a minute or two to let the butter melt before serving.