change the sql statement as below
SqlCommand cmd = new SqlCommand("insert into Exe_ContactDetails values(@Name,@Mobile,@Address,(Select ID from Team_Registration where UserName=@username))", con);
now you can set the username parameter
cmd.Parameters.AddWithValue("@username", Session["New"].ToString());