While I don't have a definitive answer, I believe Portal 2's co-op uses Peer-to-Peer multiplayer instead of dedicated servers, meaning mm_dedicated_search_maxping
wouldn't have an effect.
To explain, Peer-to-Peer multiplayer works by having players connect directly to each other instead of connecting through a centralized server.
For games like Team Fortress 2 or Counter Strike, dedicated centralized servers make sense. You have games with multiple players (up to 32 for TF2) in a match at once. Matches are competitive, meaning you don't want any one player to have a host advantage. There's a public server browser where you can specifically select a server to play on, and users are able to host their own dedicated servers.
In contrast, Portal 2 co-op only supports two players. A dedicated server would add extra latency, meaning it would be faster to use a direct peer-to-peer connection between them. Games are co-operative, meaning you typically don't need to worry about one player having a host advantage or cheating to gain the upper hand. And most importantly, the game has no public server browser or dedicated server hosting software.
If I had to guess, the mm_dedicated_search_maxping
is likely leftover code from other Valve games that do have dedicated multiplayer servers. Additionally, Portal 2 modder Orsell also said in the Portal Mapping and Modding Discord that Portal 2 co-op uses peer to peer.
As for why you can't find any games, Portal 2 released over 13 years ago, so there likely aren't many people doing public matchmaking in multiplayer. SteamDB currently lists 1,580 players ingame. While this isn't a small number, many of these players are likely either playing single player, playing co-op with their friends, or are already in-game as opposed to matchmaking for a new game.