I'm not completely sure what your issue is, so here are some common problems and solutions.
1) Can't send or receive any messages.
Go to Settings > Messages and make sure iMessage is turned on. Under Send & Receive, make sure the addresses you want to send and receive messages to/from are selected. If the appropriate addresses do not show, confirm that you are signed into the correct Apple ID for the iPad.
2) Can't send or receive SMS messages on the iPad (text to non-Apple devices).
The iPad can not send/receive standard SMS texts on its own. It must be paired with an iPhone using the same Apple ID/Cloud account.
On the iPhone, go to Settings > Messages > Text Message Forwarding and make sure the iPad shows and is enabled.
On the iPad go to Settings > Messages and make sure you have selected the iPhone's number for both send and receive. If you don't do this, especially in the Start New Conversations section your conversations may become fragmented between the two devices.
After this, the iPad should be able to send and receive SMS text messages through your iPhone's number, so long as it has internet access. I believe it will also work when in reasonable proximity to the iPhone, even without internet access, but am not certain. My iPad has cellular, so it's not a situation I have experience with.