The Consulate is quite a useful building, dedicated to earning Envoy faster and counter-espionage. In terms of Envoy, 2 Influence point may sound small, but that bonus enhances the speed of earning Envoy dramatically, especially for Tier 1 and Tier 2 governments. Later in the game, this building enhances your counter-espionage in this city and every city with an Encampment. Since the Encampment is not a specialty District you want to build everywhere, save your time and Production and build Encampments only in your major cities (like your major Production centers when going for a Scientific Victory, or your Tourism center with the Tourism-boosting Governor in it). That also means Vietnam, the only civilization in the game who wants to build Encampments in every city, absolutely loves this building. As if Vietnam is not already the most defensive civilization in the game, the fact that their District are built to surround the Thành makes counterespionage very efficient for them, and this building just adds an additional layer on top of that.
The major challenge of the Consulate is deciding when to build it, since the Diplomatic Quarter is not usually high on the priority list and tends to get ignored for a while after being unlocked. This district should be constructed early if you're going for a Diplomatic Victory and/or have Monarchy as your government, in which case the Consulate should be built immediately afterwards. Otherwise, this district and building can wait until later into the game when Spies start to get active.
A consulate refers quite simply to the place of work of a consul – in this meaning, a lesser version of an ambassador and intended to carry out the functions of an embassy on a smaller scale. A country might set up a consulate in New York, for instance, in order to help its citizens who live or visit there, whereas the main embassy might be in Washington, D.C. Here, “consulate” refers not necessarily to this, but to a facility constructed to house foreign dignitaries close to the capital – and close under watch.