It is not safe to walk around Mexico City at night, regardless if you're accompanied by someone (and especially if you're alone!) I highly recommend spending a little extra on private transportation if you're going out after dark.