Self-supporting titanium carbide and nitride modified electrodes for lithium metal batteries