In addition to adding these attributes to your Id column:
[Key]
[DatabaseGenerated(DatabaseGeneratedOption.Identity)]
public Guid Id { get; set; }
in your migration you should change your CreateTable
to add the defaultValueSQL
property to your column i.e.:
Id = c.Guid(nullable: false, identity: true, defaultValueSql: "newsequentialid()"),
This will prevent you from having to manually touch your database which, as you pointed out in the comments, is something you want to avoid with Code First.