Can I use an esp32 as an nrfl01?

If it helps, here is a tested example of a RF24 module connected to an ESP32 DevKit board. It is a slave (receiver) only, but could be the basis for a master (transmitter) as well.

// SimpleRx - the slave or the receiver

//name >> rf24 pin >> ESP32 pin
//MOSI     6            23
//MISO     7            19
//SCK      5            18
//Vcc      2            3.3V 
//                      10uF electrolytic cap between Vcc and GND on the module
//GND      1            GND  

#include <SPI.h>
#include <nRF24L01.h>
#include <RF24.h>

#define CE_PIN   22  // rf24 pin 3
#define CSN_PIN 21   // rf24 pin 4

const byte thisSlaveAddress[5] = {'R','x','A','A','A'};

RF24 radio(CE_PIN, CSN_PIN);

char dataReceived[14]; // this must match dataToSend in the TX
bool newData = false;

//===========

void setup() {

    Serial.begin(115200);

    Serial.println("SimpleRx Starting");
    radio.begin();
    radio.setDataRate( RF24_250KBPS );
    radio.openReadingPipe(1, thisSlaveAddress);
    radio.startListening();
}

//=============

void loop() {
    getData();
    showData();
}

//==============

void getData() {
    if ( radio.available() ) {
        radio.read( &dataReceived, sizeof(dataReceived) );
        newData = true;
    }
}

void showData() {
    if (newData == true) {
        Serial.print("Data received ");
        Serial.println(dataReceived);
        newData = false;
    }
}

Uses code from Robin2's simple rf24 tutorial.