title: EntityFramework relationship management OnModelCreating()
body: <p>I created the following entity:</p>
  <pre><code>public record Client
      {
          public int Id { get; set; }
  
          [NotEmptyList(ErrorMessage = &quot;At least 1 client scope is required&quot;)]
          public List&lt;Scope&gt; Scopes { get; set; }
      }
  </code></pre>
  <p>And the <code>Scope</code> class:</p>
  <pre><code>public record Scope
  {
      public int Id { get; set; }
  
      public string Name { get; set; }
  }
  </code></pre>
  <p>And my DbContext looks like this:</p>
  <pre><code>public class ConfigurationDbContext : DbContext
  {
      public ConfigurationDbContext([NotNull] DbContextOptions options) : base(options)
      {
  
      }
  
      protected override void OnModelCreating(ModelBuilder modelBuilder)
      {
      }
  
      public DbSet&lt;Client&gt; Clients { get; set; }
      public DbSet&lt;Scope&gt; ApiScopes { get; set; }
  }
  </code></pre>
  <p>When I do migration and update, my table 'ApiScopes' gets foreign key with name 'ClientId'. I don't have any idea how can I generate new ClientScopes table containing the foreign key to ApiScope and that ApiScope won't get a foreign key.</p>