How to add Must-Staple RFC7633 extension while generating csr in Java

I am trying to generate CSR via Java, with OCSP Must-Staple extension (RFC 7633) OID - 1.3.6.1.5.5.7.1.24 Can anybody help me with the snippet to add the extension alone? I am able to generate the CSR without it.

if(sansdomains!=null && !sansdomains.isEmpty()) {
        String san[] = sansdomains.split(",");
        for(int i=0; i<san.length; i++) {
            GeneralName gn = new GeneralName(GeneralName.dNSName, san[i].trim());
            subjectAlternativeNames.add(gn);
        }
    }
    DERSequence subjectAlternativeNamesExtension = new DERSequence(subjectAlternativeNames.toArray(
                new ASN1Encodable[subjectAlternativeNames.size()]));
    GeneralNames subjectAltName = new GeneralNames(subjectAlternativeNamesExtension);
    Vector oids = new Vector();
    Vector values = new Vector();
    oids.add(X509Extensions.SubjectAlternativeName);
    values.add(new X509Extension(false, new DEROctetString(subjectAltName)));
    X509Extensions extensions = new X509Extensions(oids, values);
    Attribute attribute = new Attribute(PKCSObjectIdentifiers.pkcs_9_at_extensionRequest,new DERSet(extensions));
    derSet = new DERSet(attribute);
    PKCS10CertificationRequest req = new PKCS10CertificationRequest(
            signatureAlgorithm,
            subject,
            pubkey,
            derSet,
            privkey);

Above is the code I used to generate CSR with subjectAltName extension