Remove readonly attribute from directory
Here's a good link to examples of modifying file attributes using c#
http://www.csharp-examples.net/file-attributes/
based on their example, you can remove the Read Only attribute like this (I haven't tested this):
File.SetAttributes(filePath, File.GetAttributes(filePath) & ~FileAttributes.ReadOnly);
var di = new DirectoryInfo("SomeFolder");
di.Attributes &= ~FileAttributes.ReadOnly;