You can use like any texture but trigger/nodraw works well, ctl+t it to a func_nogrenades.
Extra infos: if you want to just stop soldiers you can make it just 1 unit thick, it has to be (iirc) 8 units thick to stop sticky grenades; conversely if you want soldiers to use it but stop demomen just move the brush at least 1 unit off the wall.
Bonus useless info: if you move it exactly 4 units off a surface you can use both rockets and demoman grenades BUT not stickies, this is what I did on my stupid bonus on huh.
Also if you are curious. To make stickies not stick to a wall simply make a 1 unit thick brush and tie it to a func_brush, then set one of its properties to 'dont render'.