Prevent Archive URLs

WordPress generates date archives automatically, it’s just a thing it does. You see the index.php template probably because there isn’t a more specific one for date archives in your current theme. There are plugins that disable these archives, Yoast SEO is one.

A quick fix is to empty the date archive rewrite rules:

add_filter( 'date_rewrite_rules', function( $rules ){
    return array();
} );

Visit the Settings > Permalinks page after adding this to flush rules.