That's because of CreateDirectory... hence you may use :
match Directory.Exists("c:/mydir") with
| true -> ()
| false ->
ignore <| Directory.CreateDirectory("c:/mydir")
printfn "%s\n" "Directory created with success."
or, equivalently,
match Directory.Exists("c:/mydir") with
| true -> ()
| false ->
let _ = Directory.CreateDirectory("c:/mydir")
printfn "%s\n" "Directory created with success."