Install second wordpress in root subfolder, Error 404

I didn’t work with Apache for quite a while, so this is untested.
RewriteBase is the base for your rewrite, so it’s added to your rule automatically and your .htaccess should look something like this:

RewriteEngine On
RewriteBase /wp/
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . index.php [L]

Look here for further explanation: https://stackoverflow.com/questions/704102/how-does-rewritebase-work-in-htaccess

Also, you probably want to only put that in the .htaccess file inside your /wp directory.