could you please explain me more about the F() macro?
You could use the F() macro with an class that inherits from the Print class, so almost any library that offers print() and println() methods is a candidate. Just add the macro around a string literal and you save the RAM:
client.print("This is just an example string literal");
gets
client.print(F("This is just an example string literal"));
also how do I search for a substring on a string without using the string class.
If you work with C strings (character arrays) you can use the strstr() function to search for substrings (http://www.cplusplus.com/reference/cstring/strstr/).
In an embedded platform with that limited memory it's even better to not store that string but parse it while it drops in. Usually that results in a bit more code but saves relevant amounts of memory, depending on the area of use, of course.