TLDR: You are basically correct, but because the things you are connecting with and are not the entire verb but only a part of it, it can feel ambiguous unless you repeat some pieces. You should also remember that while Spanish allows subjects to be omitted whenever no confusion would arise, English only allows that omission under extremely limited circumstances. This is one where English does allow that omission, though, provided that you’re careful enough.
Abstract Discussion
When you have a compound verb sharing the same subject, there is no need to repeat the same subject. This is the same in English as it is in Spanish. So both these kinds of thing are perfectly common in English:
- I called and left a message.
- Every morning, Maria gets up before her kids and makes them a fancy breakfast.
Besides having omitted a to in need to, the trouble you’re having with your own sentence is that you are using a negative, and so it isn’t always clear whether it’s best to use:
- not A and B
- not A nor B
- not A and not B
- neither A nor B
The first one is ambiguous because one does not know for sure which of these two applies:
- (did not A) and (did B)
- did neither (A nor B)
Leading to things like this:
- I didn’t forgive and forget.
- I didn’t forgive nor forget.
- I didn’t forgive and didn’t forget.
- I neither forgave nor forgot.
- Neither did I forgive nor forget.
Sometimes it feels clearer in English to repeat the subject for this situation:
- I did not forgive, and I did not forget.
- I did not forgive, nor did I forget.
- I did not forgive; neither did I forget.
- Neither did I forgive nor did I forget.
If you want only the first part to be negative and the second positive, using but for a conjunction works better:
- not A but B
Thereby producing:
- I didn’t forget but did forgive.
- I didn’t forget but I did forgive.
You can also use yet for a conjunction here in English:
- not A yet B
Leading to:
- I didn’t forget yet did forgive.
- I didn’t forget yet I did forgive.
Be aware, however, that this elevates the tone somewhat because yet is less commonly used than is but here.
Concrete Application
Your original is trickier because the first verb phrase is really need to forget and the second is must forget, both negated. You’re actually trying to join together two “helper” verbs (need to and must) with a shared target infinitive (forget) which both helper parts are expected to apply to equally. That means that the and does not apply to entire verbal phrase following, only to a piece of it. This leads to a slight possible ambiguity which is most easily clarified by repeating the subject.
Moreover, one is a regular tensed verb that takes a to-infinitive complement but the other is an untensed modal verb that takes a complement of a bare infinitive, which is another potential source of confusion.
This makes it hard to find the right place to put the and. You need to put it after the need to because the to shouldn’t really apply to the half of the compound verb with a modal.
- You don’t need to — and must not — forget.
This is smoother with a repeated subject, although both of these are somewhat formal or literary:
- You neither need to — nor must you — forget.
- You don’t need to forget, nor must you.
This is much easier if both pieces you are trying to join are the same sort of thing. For example, with two auxiliary verbs both taking simple infinitive complements:
- You can and must forget it.
- I could and did forget it.
- I shouldn’t and mustn’t forget it.
- I shall not and will not forget it.
- I shan’t and won’t forget it.
- I need not and must not forget it.
[NB: When you negate need to this way, it becomes a true modal and so you may skip the to.]
- He need not and must not forget it.
By the way, your Spanish example would have worked a little better if you’d used some named third-person subject, since there’s no reason to use tú there in Spanish apart from emphasis, since it’s built into the verb conjugation already:
- No necesitas y no debes olvidar.
- Ni necesitas ni debes olvidar.
But with an explicitly named third-person subject, you then have a scenario that better maps to English usage:
- María no necesita y no debe olvidar.
- María ni necesita ni debe olvidar.
Because you are using need to in English and so have a verb plus a particle in one half but not in the other, a situation more parallel to that in Spanish would be if one were to use tienes que for the first part and only a simple debes in the second. I leave it to your own ear to decide whether these sound nice to you:
- María no tiene que y no debe olvidarlo.
- María ni tiene que ni debe olvidarlo.
Notice though how in the first sentence of my previous paragraph, I used a compound verb with a shared subject: You applies to both are using and have in that sentence, joined with an and. So you can and often do do these things in English.
It just becomes trickier when the pieces you are joining together are ambiguous because they are not the entire verbal phrase, only a piece of them. When there are ambiguities of precedence of operators like and in speech, we cannot use parentheses as we might in algebra. The best strategy in human language for resolving ambiguities caused by that sort of thing is to reword into a longer phrasing.
Postscript
Now you’ve gone and got the lyric of “La Cucaracha” running through my head:
La cucaracha la cucaracha
ya no puede caminar
porque le falta y no tiene
marijuana que fumar.
This one I blame on la María. :)