how an array index could be a file path

The string given by $plugin_path is used as an array key for $wp-plugin_paths, this is pretty standard behaviour in setting an array so it can be accessed later, to retrieve $plugin_realpath via $wp_plugin_paths[$plugin_path].

If you want to see how it all comes out you can do:

add_action('init','print_plugin_paths');
function print_plugin_paths() {
    global $wp_plugin_paths;
    foreach ($wp_plugin_paths as $key => $value) {
        echo "Plugin Path: ".$key." - ";
        echo "Real Path: ".$value."<br>";
    }
}