In order to change the title programmatically, you can access properties of the chart control and set some other values:
var chartSeries = test1.Series.First();
chartSeries.SeriesTitle = "New title";
Also you can create and add series in C# code:
var series = new ChartSeries();
series.ItemsSource = items; // a collection from somewhere else
series.DisplayMember = "dataName";
series.ValueMember = "dataValue";
series.SeriesTitle = "Title";
test1.Series.Add(series);