This is not able to be done with text channels, but it is able to be done for voice channels.
By disallowing the
Connect permission for the role of your choice (either at the
Category permission level or the
Channel permission level,) members of your server with the aforementioned role will be able to see the voice channel, but not be able to click it (or connect to it). Disallowing the
View Channel permission will remove its visibility entirely.
Beware: Members with the
Move Members permission will ignore the disallowed
Connect permission. Members with this permission may also move other users into any channel they can see, regardless of whether that user or the user they're moving has the
Connect permission for that voice channel or not.
Here's a screenshot of the permission you're looking for:
Doing something similar for a text channel is not currently possible. Disallowing the
Read Message History permission will still permit users to see messages in the related channel, however only while the channel is focused by them (the history is cleared each time the channel is no longer focused). Disallowing the
View Channel permission simply hides the text channel entirely.